RE: Is there a better way of listing Windows shares other than us ing "os.listdir"

2004-12-30 Thread Tim Golden
[EMAIL PROTECTED] | I'm currently using "os.listdir" to obtain the contents of | some slow Windows shares. I think I've seen another way of | doing this using the win32 library but I can't find the | example anymore. It may be FindFilesIterator, recently added to the win32file module in pywin

ANN: NetEpi (pre-alpha) - tools for epidemiology and public health

2004-12-30 Thread Tim Churches
ramework, the eGenix MxDateTime module, the pyPGSQL DB-API package, Numeric Python, and the RPy package which interfaces Python with R (and thanks to the R development team for the R statsistics package, of course). Tim C Sydney, Australia -- http://mail.python.org/mailman/listinfo/python-list

Python limericks (was Re: Text-to-speech)

2005-03-20 Thread Tim Churches
Steve Holden wrote: > Tim Churches wrote: >> There once was a language called Python... >> >> (which is pretty close to having three anapaestic left feet) >> >> or more promisingly, rhyme-wise, but metrically rather worse : >> >> There once was a

Re: Submission for Python Limmerick Contest

2005-03-23 Thread Tim Jarman
[EMAIL PROTECTED] wrote: > My submission for P.L.C. > > > A mathematican named van Rossum > went hunting for opossum > he could not find one > all eaten by Python > to her his language he named as a blossum > > > > wish me luck > > Harald At the prompt, when I type "import this", it Invite

Re: intrusive posts

2005-03-23 Thread Tim Churches
.sourceforge.net/ Works a treat. There once was a reverend called Bayes, Who mooned in peculiar ways. He'd show his prior To any admirer, But to see his posterior, you pays! [Source: http://www.amstat.org/sections/spes/GRC2001/Limericks2001.htm ] Tim C -- http://mail.python.org/mailman/listinfo/python-list

Re: possible bug?

2005-03-23 Thread Tim Roberts
C:\\Program Files\\WinRK\\WinRK.exe -create ' + or Command_String = r'C:\Program Files\WinRK\WinRK.exe -create ' + -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Changing the value of a for loop index on the fly

2005-03-23 Thread Tim Roberts
; is just a normal function that creates the list [0,1,2,3,4]. The "for" statement keeps running the loop until it runs out of values in that list or tuple. So, you CAN change the value of i, but it won't change the operation of the loop. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Data types

2005-03-24 Thread Tim Jarman
[EMAIL PROTECTED] wrote: > I am new to python and learning it. Can you please give me a simple > example of user defined type through class mechanism. Python 2.4 (#1, Dec 31 2004, 17:21:43) [GCC 3.3.2 (Mandrake Linux 10.0 3.3.2-6mdk)] on linux2 Type "help", "copyright", "credits" or "license" for

Grouping code by indentation - feature or ******?

2005-03-25 Thread Tim Tyler
What do you guys think about Python's grouping of code via indentation? Is it good - perhaps because it saves space and eliminates keypresses? Or is it bad - perhaps because it makes program flow dependent on invisible, and unpronouncable characters - and results in more manual alignment issues

Re: Suggesting a new feature - "Inverse Generators"

2005-03-25 Thread Tim Hochberg
dline): optionalline = iterator.next() lastline = iterator.next() yield createRecord(firstline, secondline, optionalline, lastline) ??? -tim def getData(lines): return list(combineIntoRecords(filterJunk(lines))) So, alas, my beloved for loop was not saved after all. Fortunately, the dr

Re: character-filtering and Word (& company)

2005-03-25 Thread Tim Churches
translate() because I don't know > how to predict what the incoming format will be. > > Any hints welcome. Antiword? See http://www.winfield.demon.nl/ OpenOffice driven via PyUNO interface? Tim C -- http://mail.python.org/mailman/listinfo/python-list

Re: Cpickle module... not in Lib installs

2005-03-25 Thread Tim Jarman
Marcus Lowland wrote: > Thanks Marc, but... I've searched the file directories for cpickle (not > specifying file type) and only came up with test_cpickle.py. Also, if > cPickle.so were the correct file and existed in my lib then the > following would not happen. > import cpickle > > Traceb

Re: Bug in threading.Thread.join() ?

2005-03-25 Thread Tim Peters
[Peter Hansen] > I'm still trying to understand the behaviour that I'm > seeing but I'm already pretty sure that it's either > a bug, or something that would be considered a bug if > it didn't perhaps avoid even worse behaviour. > > Inside the join() method of threading.Thread objects, > a Conditio

Re: DBAPI Paramstyle

2005-03-26 Thread Tim Roberts
that the database provider inserts whatever quoting is required; you don't have to remember to put single quotes around the arguments, and protect single quotes within the arguments by doubling them, and so on. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: ANN: Twisted version 2.0

2005-03-26 Thread Tim Roberts
be answered with a 4-line application using Twisted, but now it's grown even more? Remember the Master Control Program from Tron? I think of Twisted as Python's MCP. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: float default formatting

2005-03-26 Thread Tim Roberts
ef="+FLT) % (3.0,4.5) Are you trying to do currency? There are better ways, using the locale methods. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Grouping code by indentation - feature or ******?

2005-03-26 Thread Tim Roberts
st of 1,000+ evils." Or, paraphrasing Mark Twain, "Python is the worst possible programming language, except for all the others." -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: html tags and python

2005-03-26 Thread Tim Roberts
t; much quicker. To do that with your code, I have to type "m tab 2 2 2 2 2 2 tab 2005". As an alternative, there are Javascript-based mini-calendars you can download that popup a little window with the current month, and let you click on the date. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Grouping code by indentation - feature or ******?

2005-03-26 Thread Tim Tyler
Peter Otten <[EMAIL PROTECTED]> wrote or quoted: > I, Tim Tyler wrote: > > What do you guys think about Python's grouping of code via indentation? > > This is a Python newsgroup. Assume that we all have been brainwashed. ;-) I had a good look for comp.lang.python.

Re: Grouping code by indentation - feature or ******?

2005-03-26 Thread Tim Tyler
Javier Bezos <[EMAIL PROTECTED]> wrote or quoted: > "Tim Tyler" <[EMAIL PROTECTED]> escribi? en el mensaje > > What do you guys think about Python's grouping of code via indentation? > > > > Is it good - perhaps because it saves space and elimina

[Tkinter] LONG POST ALERT: Setting application icon on Linux

2005-03-27 Thread Tim Jarman
icon. import os.path import Tkinter as tk APP_NAME = "Icon Test" HOME = "/home/tim/Projects/tkDev/playwright" def main(): "Main entry point for the application." # Create the root window. root = tk.Tk() root.title(APP_NAME) # Set the

Re: [Tkinter] LONG POST ALERT: Setting application icon on Linux

2005-03-27 Thread Tim Jarman
olor images with > "iconbitmap" on Linux. Tk doesn't support _NET_WM_ICON for setting > full-color icons. > > Jeff Thanks for this, Jeff - I'll do some digging in the Tk docs. My problem is that I'm trying to use iconwindow() to use a colour image, as

Re: [Newbie] How do I get better at Python programming?

2005-03-29 Thread Tim Jarman
Roy Smith wrote: > keep in mind, however, that not all problems in life can be solved with > software. +1 QOTW -- Website: www DOT jarmania FULLSTOP com -- http://mail.python.org/mailman/listinfo/python-list

Re: Grouping code by indentation - feature or ******?

2005-03-29 Thread Tim Roberts
ion did not really say "^L". It gave me the symbol for female, which is code point 12 in the default character set. I translated it to the VIM equivalent to make the point.) -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: File Uploads

2005-03-30 Thread Tim Roberts
ur problem solved, but you should know there is a problem with this line. The print statement automatically adds an end-of-line, so this will actually end up producing TWO blank lines after the header. You should use this: print "Content-type: text/html\n" -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Newbie Shell Editor Question

2005-03-30 Thread Tim Roberts
I don't know IDLE, but it's probably something like File->Run. >>>> exit >'Use File/Exit or your end-of-file key to quit IDLE' >>>> print "Hello" >Hello THAT'S the way you use IDLE. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: redundant imports

2005-03-30 Thread Tim Jarman
7;re probably aware, Python also caches compilation results in *.pyc files; it will only compile the imported module if it changed since the last compilation. Check out the docs for the full skinny, in particular http://www.python.org/doc/2.4/ref/import.html HTH, Tim J -- Website: www DOT jarmania FULLSTOP com -- http://mail.python.org/mailman/listinfo/python-list

Re: Good use for Jython

2005-03-30 Thread Tim Tyler
Mike Wimpe <[EMAIL PROTECTED]> wrote or quoted: > Other than being used to wrap Java classes, what other real use is > there for Jython being that Python has many other GUI toolkits > available? Also, these toolkits like Tkinter are so much better for > client usage (and faster) than Swing, so wha

Re: math - need divisors algorithm

2005-03-30 Thread Tim Peters
[Philp Smith] > Does anyone have suggested code for a compact, efficient, elegant, most of > all pythonic routine to produce a list of all the proper divisors of an > integer (given a list of prime factors/powers) If the canonical factorization of N is the product of p_i**e_i, the number of diviso

Re: [Tkinter] LONG POST ALERT: Setting application icon on Linux

2005-03-31 Thread Tim Jarman
pec, too. If KDE > supports NET_WM_ICON, this may work for you (but you'll have to convert > your image manually to the format required for NET_WM_ICON) > > Best of luck! Unfortunately, the code is not supported. > > Jeff Thanks very much for the link! I'll take a look. Tim

Re: hex string into binary format?

2005-04-01 Thread Tim Roberts
;i1 = binascii.unhexlify(s1) >i2 = binascii.unhexlify(s2) >x = i1 ^i2 > > TypeError: unsupported operand type(s) for ^: 'str' and 'str' No imports at all: s1 = '1C46BE3D9F6AA820' s2 = '8667B5236D89CD46' i1 = int(s1,16) i2 = int(s2,16) x =

Re: urllib problem (maybe bugs?)

2005-04-01 Thread Tim Roberts
't do that. It always sends plain old application/x-www-form-urlencoded data. I think you're going to have to roll your own sender. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: boring the reader to death (wasRe: Lambda: the Ultimate Design Flaw

2005-04-01 Thread Tim Peters
[Aahz] >> "The joy of coding Python should be in seeing short, concise, readable >> classes that express a lot of action in a small amount of clear code -- >> not in reams of trivial code that bores the reader to death." --GvR [Sunnan] > Can anyone please point me to the text that quote was taken

Re: Simple thread-safe counter?

2005-04-01 Thread Tim Peters
[Paul Rubin] > I'd like to have a function (or other callable object) that returns > 0, 1, 2, etc. on repeated calls. That is: > >print f() # prints 0 >print f() # prints 1 >print f() # prints 2 ># etc. > > There should never be any possibility of any number getting returned

Re: How to reload local namespace definitions in the python interpreter?

2005-04-02 Thread Tim Jarman
[EMAIL PROTECTED] wrote: > Hi, > > I am a beginner using the python interpreter. To reduce typing effort, > I created a module called "aliases.py" containing some aliases for > objects I commonly use like - > > aliases.py : > > > import filecmp, os, commands > > op = os.path > go = commands.g

Re: Simple thread-safe counter?

2005-04-02 Thread Tim Peters
[Paul Rubin] > I'm starting to believe the GIL covers up an awful lot of sloppiness > in Python. The GIL is highly exploitable, and much of CPython does exploit it. If you don't want to exploit it, that's fine: there was always an obvious approach using an explicit mutex here, and the only thing

Re: DIY Spam Filter in Python

2005-04-04 Thread Tim Churches
bers.ozemail.com.au/~pballard/ Pete mate, Nice work, but your Web page on your DIY Spam Filter doesn't mention SpamBayes, which is surely the definitive Pythonic spam filter, as well as being eerily effective - see http://spambayes.sourceforge.net Not sure that the Reverend Bayes would have agree

Status of Chaco?

2005-04-04 Thread Tim Lesher
ave it released within > the next few weeks. Is Chaco dead? Or just pining? -- Tim Lesher <[EMAIL PROTECTED]> -- http://mail.python.org/mailman/listinfo/python-list

Re: IronPython 0.7 released!

2005-04-05 Thread Tim Peters
hink Guido is good. Therefore all things that happen in this world are good. I know, it takes a bit of practice to truly believe that . not-mentioning-that-i-don't-feel-particularly-embraced-yet-ly y'rs - tim -- http://mail.python.org/mailman/listinfo/python-list

Re: Best editor?

2005-04-06 Thread Tim Keating
I bought the Komodo personal edition, and at only $30, it is worth it for the regular expression toolkit alone. -- http://mail.python.org/mailman/listinfo/python-list

Re: sorting a list and counting interchanges

2005-04-06 Thread Tim Peters
[RickMuller] > I have to sort a list, but in addition to the sorting, I need to > compute a phase factor that is +1 if there is an even number of > interchanges in the sort, and -1 if there is an odd number of > interchanges. So you want the parity ("sign") of the associated permutation. > I coul

Re: sorting a list and counting interchanges

2005-04-07 Thread Tim Peters
[Paul Rubin] > Writing a sorting function from scratch for this purpose seems like > reinventing the wheel. Yup! list.sort() is going to be mounds faster. > Tim's answer of simply counting the cycles (without having to pay > attention to their length) is really clever. I didn't realize you coul

Re: struct enhancements?

2005-04-07 Thread Tim Peters
[EMAIL PROTECTED] > I would like to be able to pack/unpack 8-byte longs, ... Have you tried struct's 'q' or 'Q' format codes? -- http://mail.python.org/mailman/listinfo/python-list

Re: change extensions

2005-04-07 Thread Tim Roberts
"Bob Then" <[EMAIL PROTECTED]> wrote: >how can i change all files from one extension to another within a direcory? In Windows, the quickest way is: os.system( "rename *.old *.new" ) -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -

Re: Grouping code by indentation - feature or ******?

2005-04-08 Thread Tim Tyler
I, Tim Tyler <[EMAIL PROTECTED]> wrote or quoted: > What do you guys think about Python's grouping of code via > indentation? Some relevant resources: http://c2.com/cgi/wiki?PythonWhiteSpaceDiscussion http://c2.com/cgi/wiki?IndentationEqualsGrouping http:

Re: Positions of regexp groups

2005-04-08 Thread Tim Peters
[Magnus Lie Hetland] > Just a quick question: Does anyone have a simple way of finding the > positions (start, end) of the groups in a regexp match? AFAICS, the re > API can only return the contents...? Read the docs for match objects, esp. the start(), end(), and span() methods. -- http://mail.p

Are circular dependencies possible in Python?

2005-04-09 Thread Tim Tyler
Like C, Python seems to insist I declare functions before calling them - rather than, say, scanning to the end of the current script when it can't immediately find what function I'm referring to. C lets you predeclare functions to allow for the existence of functions with circular dependencies. D

Re: Are circular dependencies possible in Python?

2005-04-09 Thread Tim Tyler
Tim Tyler <[EMAIL PROTECTED]> wrote or quoted: > Like C, Python seems to insist I declare functions before calling > them - rather than, say, scanning to the end of the current script > when it can't immediately find what function I'm referring to. > > C lets yo

Re: How to detect if file is a directory

2005-04-09 Thread Tim Jarman
César Leonardo Blum Silveira wrote: > Hello all, I'm new to this list. > > How can I detect if a file is a directory or not? > > Thanks > > César The os module contains many helpful tools for working with files, directories, links and so forth. Check out the docs and marvel. The following snip

Re: Https Form Page

2005-04-09 Thread Tim Roberts
>http=httplib.HTTP("https://www.abc.com/",443) If you want https, you should use the HTTPS class. http = httplib.HTTPS("https://www.abc.com/",443) Or, even better, the HTTPSConnection class. http://www.noah.org/python/https/ -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Are circular dependencies possible in Python?

2005-04-10 Thread Tim Tyler
Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote or quoted: > In <[EMAIL PROTECTED]>, Tim Tyler wrote: > > Like C, Python seems to insist I declare functions before calling > > them - rather than, say, scanning to the end of the current script > > w

Re: Python 2.4 killing commercial Windows Python development ?

2005-04-11 Thread Tim Peters
[Michael Kearns] > ... > Also, I don't believe that just 'owning' MSVC 7.1 is enough. From > cursory glances at the various redist files, I would also have to ship > the EULA, and as an end-user (of python) I can't just redistribute the > files - perhaps I could write a place holder application in

smtplib STARTTLS problems

2005-04-12 Thread Tim Williams
I have a working SMTP client that I need to add TLS capability to,I absolutely need the client to timeout within a specified time, but when I use the sock.timeout() line it freezes the reading of chars from SSLFakeFile used during TLS instead of timing out the client connection.I am worki

[ANN]: mkapachepw 1.21 Released And Available

2005-04-12 Thread Tim Daneliuk
n to work on FreeBSD. See the web page for licensing terms and the complete documentation. -- Tim Daneliuk [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list

Re: A command in a String ?

2005-04-13 Thread Tim Daneliuk
trying to do this that as I am aware the OptionMenu hasn't the ability insert options therefore the options would be inserted by manipulating strings. Pete Look into the "eval" operation ... -- -------- T

Re: Global Variables

2005-04-13 Thread Tim Roberts
It means that your function has "side effects" beyond just returning a value or set of values. This kind of thing is a better solution: def change_filename(): return raw_input() def change_path() return raw_input() filename = change_filename() path = change_path() -- -

RE: Get OS name

2005-04-15 Thread Tim Golden
[rbt] | | codecraig wrote: | > How can I get the OS Name, such as "Windows XP Pro". I | know I can do | > | > sys.getwindowsversion but that doesnt return a nice Windows XP Pro | > string. | > | > and os.name gives "nt" | > | > thanks. | > | | Read the docs... sys.getwindowsversion() should

RE: Get OS name

2005-04-15 Thread Tim Golden
[codecraig] | where can I get wmi module, it doesnt come with Python right? | Sorry, should have said. http://timgolden.me.uk/python/wmi.html TJG This e-mail has been scanned for all viruses by Star. The service is power

Re: Compute pi to base 12 using Python?

2005-04-16 Thread Tim Roberts
t, even not a >># pi-sonnet, but it surely produces Pi! > >It sure does. When I ran it my jaw dropped. I had 7,947 CORRECT digits in >2 minutes 0 seconds (by my stopwatch)! How do you know? I think the 7,912th digit is wrong. ;) -- - Tim Roberts, [EMAIL PROTECTED] Providenza &

Re: Compute pi to base 12 using Python?

2005-04-16 Thread Tim Roberts
I'm >planning to put the contents of UnxUtils.zip in a directory and then move >the contents of UnxUpdates.zip, which has many of the same filenames, to >the same directory. Should I just let Windows replace the old files with >the updated ones? Yes. -- - Tim Roberts, [EMA

Re: Parse command line options

2005-04-18 Thread Tim Daneliuk
. For options that are just switches (that take no argument), I believe they should appear in the list above *without* the colon suffix... -- ---- Tim Daneliuk [EMAIL PROTECTED] PGP Key: http://www.tundraw

Re: Proposal: an unchanging URL for Python documentation

2005-04-18 Thread Tim Peters
[Steve] > I have a suggestion/request that will, I think, improve the Python > documentation. > > Currently, the Python documentation in HTML format is stored at URLs > that change with each new release of Python. That is, for example, the > documentation for the os module is at > http://python.or

RE: Name/ID of removable Media: how?

2005-04-19 Thread Tim Golden
[Heiko Selber] | I am trying to find out (using Python under windows) the name | of a CD that | is currently in the drive specified by a path name. | | And while I am at it, I'd also like to know whether the | specified drive | contains a CD at all, and whether the drive is actually a CD drive.

RE: Name/ID of removable Media: how?

2005-04-19 Thread Tim Golden
[Ivan Van Laningham] | Hi All-- | Tim's wmi stuff looked interesting, so I tried it out, and | now I have a | question. | [... snip code ...] | The output from the above script (drive d contains cd) is: | | WMI serial D0ADBEE7 3501047527 | | win32api serial -793919769 -793919769 | | | What'

RE: Name/ID of removable Media: how?

2005-04-19 Thread Tim Golden
[Ivan Van Laningham] | Hi All-- | | Tim Golden wrote: | > | > Try this: hex (-793919769) | > | > You might need to check back on recent discussions here re | > negative / positive numbers and hexadecimal. | > | > (Short version: we used to treat hex numbers with the top bi

Re: How to run Python in Windows w/o popping a DOS box?

2005-04-19 Thread Tim Peters
[Paul Rubin] > Dumb question from a Windows ignoramus: > > I find myself needing to write a Python app (call it myapp.py) that > uses tkinter, which as it happens has to be used under (ugh) Windows. > That's Windows XP if it makes any difference. Nope, the Windows flavor doesn't matter. > I put a

python-dev Summary for 2005-04-01 through 2005-04-15

2005-04-20 Thread Tim Lesher
by the team of Steve Bethard, Tim Lesher, and Tony Meyer. We're trying a collaborative approach to the summaries: each fortnight, we'll be getting together in a virtual smoke-filled back room to divide up the interesting threads. Then we'll stitch together the summaries in roughly t

Re: python LEX

2005-04-21 Thread Tim Daneliuk
/ -- Tim Daneliuk [EMAIL PROTECTED] PGP Key: http://www.tundraware.com/PGP/ -- http://mail.python.org/mailman/listinfo/python-list

Re: python LEX

2005-04-21 Thread Tim Daneliuk
Tim Daneliuk wrote: jozo wrote: I have to work on python lexical definition in Lex. I spent lots of my time to find regular expresions written for Lex of Python language but nothing. Can somebody help me? I nEED hELP http://systems.cs.uchicago.edu/ply/ Whoops - I did not read your question

Re: goto statement

2005-04-21 Thread Tim Daneliuk
little to do with just what language structures are in use. Python is elegant at almost every level, and I am certainly not arguing for 'goto' in the language. But to reflexively assume that it has *no* place in a modern HLL is, I think, a bit overstated. I must now 'goto' sleep ..

Manipulating large blobs in Python

2005-04-21 Thread Tim Stone
files... do I need some version of visual studio ide to do the windows compile? It'd be great if there was some way to increase the heapsize without all that bother :) Tim Stone -- http://mail.python.org/mailman/listinfo/python-list

Re: time.strftime in 2.4.1 claims data out of range when not

2005-04-22 Thread Tim Peters
[Sheila King] > I have a web app that has been running just fine for several months under > Python 2.2.2. > > We are preparing to upgrade the server to run Python 2.4.1. > > However, part of my web app is throwing an error on this code (that has > previously worked without exception): > > >>> time.

Re: Python or PHP?

2005-04-23 Thread Tim Tyler
Mage <[EMAIL PROTECTED]> wrote or quoted: > check this: http://wiki.w4py.org/pythonvsphp.html Good - but it hardly mentions the issue of security - which seems like a bit of a problem for PHP at the moment. -- __ |im |yler http://timtyler.org/ [EMAIL PROTECTED] Remove lock to reply.

Re: Python licence again

2005-04-23 Thread Tim Tyler
fuzzylollipop <[EMAIL PROTECTED]> wrote or quoted: > try spelling license correctly next time and heading the google > suggestions that probably looked like "didn't you mean : Python License" How do you spell license correctly? -- __ |im |yler http://timtyler.org/ [EMAIL PROTECTED] R

Re: Python or PHP?

2005-04-24 Thread Tim Tyler
Mage <[EMAIL PROTECTED]> wrote or quoted: > Tim Tyler wrote: > >Mage <[EMAIL PROTECTED]> wrote or quoted: > >>check this: http://wiki.w4py.org/pythonvsphp.html > > > >Good - but it hardly mentions the issue of security - which seems > >like a bit

Re: Quote-aware string splitting

2005-04-25 Thread Tim Heaney
"J. W. McCall" <[EMAIL PROTECTED]> writes: > > I need to split a string as per string.strip(), but with a > modification: I want it to recognize quoted strings and return them as > one list item, regardless of any whitespace within the quoted string. > > For example, given the string: > > 'spam "th

Re: Getting into Python, comming from Perl.

2005-04-26 Thread Tim Roberts
me to >jump ship (to mix my metaphors). That is truly wonderous. Are you famliar with the phrase "jumping the shark"? This chart might prove that, with Perl 6, Perl has now "jumped the shark". -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

ADODB Currency type broken in Python win32?

2005-04-26 Thread Tim Roberts
myMoney 6 (0, 25L) Instead, we get: myMoney 6 (0, -1794967296) The value has wrapped at 2**31. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Python Challenge ahead [NEW] for riddle lovers

2005-04-30 Thread Tim Peters
[Mike Rovner] > 3 IS wrong because if you use any not BIG letter after bodyguard on both > sides, you get extra 'eCQQmSXK\n' which slow me down for 5 minutes. Get rid of the newlines first. On level 7, I'm not sure whether there's something more to do, or whether I'm looking at a bug in how IE di

Re: PyMyth: Global variables are evil... WRONG!

2013-11-11 Thread Tim Daneliuk
Interesting read. Thanks for taking the time -- ---- Tim Daneliuk tun...@tundraware.com PGP Key: http://www.tundraware.com/PGP/ -- https://mail.python.org/mailman/listinfo/python-list

Re: To whoever hacked into my Database

2013-11-12 Thread Tim Chase
On 2013-11-11 22:24, ru...@yahoo.com wrote: > And your suggestion is not necessarily best either: why a 1:M > relationship? why not a M:M relationship? There may be duplicate > file downloads resulting in your suggestion being non-normalized. You think that, after rejecting the addition of *one*

Re: PyMyth: Global variables are evil... WRONG!

2013-11-12 Thread Tim Chase
On 2013-11-11 20:46, Rick Johnson wrote: > Yes, and i agree. But you cannot "hide" everything. There > will always be a need to share information. You may not be able to (or want to) hide everything, but sharing should at least happen over defined protocols (functions/methods). Otherwise, you wand

Re: Conditional breakpoints in ceval.c

2013-11-12 Thread Tim Golden
On 12/11/2013 15:40, Demian Brecht wrote: > On Sat, Nov 9, 2013 at 5:33 AM, wrote: >> I don't know how to use gdb the way you want, but it sounds like you are on >> a fascinating journey of discovery. What are you trying to learn? Perhaps >> we can talk about how the interpreter works. > > A

Re: datetime question

2013-11-12 Thread Tim Chase
On 2013-11-12 17:24, Ferrous Cranus wrote: > But what of the server was in California and i live in Greece? > > How would datetime.now() work then? Best practices say to move the value from local time to UTC as soon as possible, then store/use the UTC time internally for all operations. Only whe

Re: datetime question

2013-11-12 Thread Tim Chase
On 2013-11-12 17:57, Ferrous Cranus wrote: > > Best practices say to move the value from local time to UTC as > > soon as possible, then store/use the UTC time internally for all > > operations. Only when it's about to be presented to the user > > should you convert it back to local time if you ne

Re: PyMyth: Global variables are evil... WRONG!

2013-11-12 Thread Tim Chase
On 2013-11-12 09:00, Rick Johnson wrote: > Because the constant PI should never change. Sure we can > argue about granularity of PI, but that argument has no > weight on the fact that PI should be a constant. > > By placing PI in the module "math", we are creating a pseudo > interface. We (the cre

Re: Some python newb help please?

2013-11-12 Thread Tim Chase
On 2013-11-12 14:27, lrwarre...@gmail.com wrote: > if int(raw_input()) == 1: > print "Moving north" > y = y + 1 > elif int(raw_input()) == 2: > print "Moving east" > x = x + 1 > elif int(raw_input()) == 3: > print "Moving south

Re: PyMyth: Global variables are evil... WRONG!

2013-11-12 Thread Tim Chase
On 2013-11-12 18:45, Rick Johnson wrote: > "math.pi" should be "math.PI". It's a real shame that this fails: >>> math.PI = math.pi oh...wait... > and PI should be a CONSTANT. And not just a pseudo constant, but a > REAL constant that cannot be changed. How much precision do you want? Perhap

Re: change volume of single audio device

2013-11-13 Thread Tim Chase
On 2013-11-13 16:05, Steven D'Aprano wrote: > Start by googling for "mixerSetControlDetails return value 11" and > go on from there. Sounds like Nigel at work.[1] -tkc http://en.wikipedia.org/wiki/Up_to_eleven -- https://mail.python.org/mailman/listinfo/python-list

Re: PyMyth: Global variables are evil... WRONG!

2013-11-13 Thread Tim Daneliuk
On 11/11/2013 10:46 PM, Rick Johnson wrote: On Monday, November 11, 2013 8:47:09 PM UTC-6, Tim Daneliuk wrote: I think this is certainly the use case most people would suggest. But I think you may have missed the real reason most modern designers object to inter-module globals: The presence of

ogg2mp3 utility?

2013-11-13 Thread Tim Johnson
27;s a "spot on" great app, but I would like to be able to "keep it all one codebase". Are there any python utility that anyone could recommend? thanks -- Tim tim at tee jay forty nine dot com or akwebsoft dot com http://www.akwebsoft.com, http://www.tj49.com -- https://mail

Re: Odd msg received from list

2013-11-14 Thread Tim Golden
On 14/11/2013 13:53, Verde Denim wrote: > I got an odd message this morning from the list telling me that my > account was de-activated due to excessive bounces. I've only sent a > handful of messages to this board, but do read an awful lot of the posts > in order to learn more about the language.

@gmail.com accounts put on hold

2013-11-14 Thread Tim Golden
Several people have reported Mailman messages notifying them of their subscription being suspended because of bounces. The notifications are pukka and appear to have resulted from a reaction by Google's mail servers to messages via this list from an invalid address at a valid domain. The Mailman

Re: Converting hex data to image

2013-11-14 Thread Tim Golden
On 14/11/2013 15:32, Shyam Parimal Katti wrote: > I am implementing an authentication system(in Django) using LDAP as the > backend(django-auth-ldap). When we fetch the data from the LDAP server > for a particular valid user, the data associated with the user contains > the thumbnail photo in hex r

Re: ogg2mp3 utility?

2013-11-14 Thread Tim Johnson
* Tim Johnson [131113 17:06]: > I've written an application that does some audio file conversions. > > I use mutagen for some of the mp3 file manipulation, but to convert > ogg files to mp3 format I've been using subprocess to run the > ogg2mp3 perl utili

Re: Running python's own unit tests?

2013-11-14 Thread Tim Golden
On 14/11/2013 19:12, Russell E. Owen wrote: I'm building python from source and trying to figure out how to test the result. I must be overlooking something obvious, but I looked through the documentation and source and tried some google searches (which turn up plenty about writing unit tests in

Re: Running python's own unit tests?

2013-11-14 Thread Tim Golden
On 14/11/2013 20:13, Zachary Ware wrote: On Thu, Nov 14, 2013 at 1:12 PM, Russell E. Owen wrote: I'm building python from source and trying to figure out how to test the result. I must be overlooking something obvious, but I looked through the documentation and source and tried some google sear

Re: PyMyth: Global variables are evil... WRONG!

2013-11-15 Thread Tim Daneliuk
moral failing or lack of discipline, it's the simple reality that what you thought you needed to deliver changed in the intervening 6 months of coding because the business changed. ---- Tim Daneliuk tun...@tundraw

Re: PyMyth: Global variables are evil... WRONG!

2013-11-15 Thread Tim Daneliuk
On 11/15/2013 09:42 AM, Chris Angelico wrote: On Sat, Nov 16, 2013 at 2:26 AM, Tim Daneliuk wrote: On 11/15/2013 02:19 AM, Steven D'Aprano wrote: Nobody sets out to*design* a tangled mess. What normally happens is that a tangled mess is the result of*lack of design*. This has be

Re: Automation

2013-11-15 Thread Tim Chase
On 2013-11-15 13:43, xDog Walker wrote: > On Friday 2013 November 15 06:58, Grant Edwards wrote: > > There are people (not many in this group) who grew up speaking > > English and really ought to apologize for their writing -- but > > they never do. > > Can you supply an example of the form such

<    13   14   15   16   17   18   19   20   21   22   >