Re: Destructive Windows Script

2005-06-08 Thread Tim Roberts
;, '^', '&', '*', ';'] >> > >Note that the backslashes are redundant between pairs >of [ ], ( ) or { }. Just write: > > data = ['0', 'a', '1', 'b', '2', 'c', &g

Re: help with sending mail in Program

2005-06-08 Thread Tim Roberts
27;mail.mycompany.com') >s.ehlo('10.0.3.160') # IP address of my computer, I don't remember why I > needed this > >msg = '''From: %s >Subject: %s >To: %s > >%s >''' % (frm, subject, to, body) >

Re: Simple SMTP server

2005-06-09 Thread Tim Williams
- Original Message - From: "Jesse Noller" <[EMAIL PROTECTED]> > I am looking at implementing a simple SMTP server in python - I know > about the smtpd module, but I am looking for code examples/snippets as > the documentation is sparse. > > If anyone has any good examples/recipes I'd gre

Re: help with sending mail in Program

2005-06-09 Thread Tim Williams
;' % (frm, subject, to, body) s.sendmail(frm, to, msg) s.sendmail(frm, [to], msg) s.quit() if __name__ == '__main__': sendToMe('test', 'test') It says it sends it but I get nothing in my inbox or anywhere! This is really frustrating me. _

Re: help with sending mail in Program

2005-06-09 Thread Tim Williams
t; msg = '''From: %s > >Subject: %s > >To: %s > > > >%s > >''' % (frm, subject, to, body) > > > > s.sendmail(frm, to, msg) > > > > s.sendmail(frm, [to], msg) > > > > s.quit() > > &

Re: Questions on using Qt or wxWindows with Python and OS X

2005-06-09 Thread Tim Jarman
UI toolkits looking for text-widget Nirvana, and the best I've found is good ol' Tk. Unfortunately Tk/Aqua is still a long way from looking lovely IMHO. You might want to check it out all the same if text processing is your thing. I'm sure there are people here who would disagree that it's "dying a slow death" just yet. ;) > Many thanks for any feedback you can give. > > > Cheers, > Ken HTH, Tim -- Remove luncheon meat to reply. -- http://mail.python.org/mailman/listinfo/python-list

Re: smtpd module

2005-06-09 Thread Tim Williams
e able to make it do what you need in a couple of minutes. If not post back and I'll knock something up :) - Original Message - From: "Tim Williams" <[EMAIL PROTECTED]> To: Sent: Thursday, June 09, 2005 3:20 PM Subject: Re: Simple SMTP server - Original Message

RE: python create WMI instances

2005-06-10 Thread Tim Golden
[Marc Wyburn] | | Hi all, I am struggling with a vb - python code conversion. I'm using | WMI to create printers on remote machines using (in VB); | | set oPrinter = oService.Get("Win32_Printer").SpawnInstance_ | | oPrinter.DriverName = strDriver | oPrinter.PortName = strPort | oPrinter.Devic

SMTP Test Rig ( SMTPRIG.PY v1.0 )

2005-06-10 Thread Tim Williams
After a few posts recently, I have put together an SMTP test rig that will receive emails and either store them to a file, write them to a console, or both. Does anyone have any suggestions on where I can get it hosted as a utility for general public use? TIA Tim -- http://mail.python.org

re: howto send html mails using smtplib

2005-06-10 Thread Tim Williams
x27;text/html') msg.add_header('Content-Type', 'text/html') HTH :) -- = Tim Williams -- http://mail.python.org/mailman/listinfo/python-list

How to use axdebug

2005-06-10 Thread Tim Hoffman
via the Windows Script Debugger. Rgds Tim -- http://mail.python.org/mailman/listinfo/python-list

Re: anygui,anydb, any opinions?

2005-06-10 Thread Tim Roberts
Renato Ramonda <[EMAIL PROTECTED]> wrote: >Tim Roberts ha scritto: > >> wx uses "sizers" to do the same thing. Same purpose, different philosophy. >> I find sizers more natural, but people should certainly stick to whatever >> makes them comfortable. >

Re: help with sending mail in Program

2005-06-11 Thread Tim Williams
ct('mail.mycompany.com') > >> s.ehlo('10.0.3.160') # IP address of my computer, I don't remember >why I needed this > >> > >> msg = '''From: %s > >>Subject: %s > >>To: %s > >> > >>%s > >>&

Re: how to operate the excel by python?

2005-06-12 Thread Tim Roberts
>"number formats" are not sensible, loss of information can result. This is a real problem. US postal codes are a particular nasty issue. The value "01234", for example, will be imported into Excel as "1234". -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: why python on debian without the module profile?

2005-06-13 Thread Tim Leslie
My understanding is that there are licence issues (someone please correct me if I'm wrong). The moral of the story is that there's a seperate (non-free) package for the profiler: http://packages.debian.org/testing/python/python2.4-profiler HTH Tim On 6/13/05, kyo guan <[EMAIL PROT

RE: [OT ?] (Pythonic) detection word protected files

2005-06-13 Thread Tim Golden
[Gilles Lenfant] | I'm building an utility that makes a catalog of M$ word files | in a giant | directory tree. The password protected files must be marked, and I | didn't find how to guess which files are password protected and which | ones are not. | | I can't use the COM interface for this

RE: windows directory

2005-06-14 Thread Tim Golden
[Austin] | I would like to write a program which creates the folders in specific | directory. | For example, I want to create folder in Program Files. How do | I know which | is in C:\ or D:\ | Is there any function to get the active path? It's not quite clear what you mean. You seem to be asking

RE: Where is Word?

2005-06-14 Thread Tim Golden
[Guy Lateur] | I need a way to get the path where MS Word/Office has been | installed. I need | to start Word from a script (see earlier post), but it | doesn't work if I | don't know its path. So "os.system("winword.exe %s" % | fileName)" doesn't | always work; I need to say "os.system("C:\P

RE: Where is Word?

2005-06-14 Thread Tim Golden
[Guy Lateur] | Unfortunately, I need to open/edit a (temporary) text file | with Word, and | those are opened by default with UltraEdit (or Notepad or..). | Thanks for the | tip, though. | | Anything else? Do I need to read the registry? | | g OK, you have a couple of options (at least). Eas

RE: Where is Word?

2005-06-14 Thread Tim Golden
[Guy Lateur] | Sent: 14 June 2005 11:02 | To: [email protected] | Subject: Re: Where is Word? | | | Unfortunately, I need to open/edit a (temporary) text file | with Word, and | those are opened by default with UltraEdit (or Notepad or..). | Thanks for the | tip, though. | | Anything el

RE: Where is Word?

2005-06-14 Thread Tim Golden
[Guy Lateur] | I want to make a temporary file (directory listing), open it | in Word to let | the user edit, layout and print it, and then delete the temp file | afterwards. I don't think we'll be able to fully automate it, | though. The | user should be able to set her own fonts and stuff.

RE: Single Application Instance Example

2005-06-14 Thread Tim Golden
[Chris Lambacher] | Does anyone know of an example of how to make a Python program only | run a single instance. I am specifically looking for examples for | win32. | | I think I should be able to do this with win32all but the method is | not obvious. Preferably I would like to be able to get a

ANN: Version 0.9 of NetEpi Case Manager

2005-06-14 Thread Tim Churches
rom anyone willing to do further work on the documentation (using OpenOffice2), and from anyone willing to write additional Selenium test scripts, either in the Selenese scripting language or in Python via the Selenium "driven" mode (or more Python unit tests, for that matter). Tim Chu

Re: Thread priorities?

2005-06-14 Thread Tim Peters
[Gary Robinson] > In the application we're writing (http://www.goombah.com) it would be > helpful for us to give one thread a higher priority than the others. We > tried the recipe here: > http://groups-beta.google.com/group/comp.lang.python/msg/6f0e118227a5f5de > and it didn't seem to work for us.

Re: help with sending mail in Program

2005-06-16 Thread Tim Williams
- Original Message - From: "Ivan Shevanski" <[EMAIL PROTECTED]> > > if __name__ == '__main__': >body = 'x is',x,'y is',y,'.Lets hope that works!' >subject = 'Neo' >sendToMe(subject, body) > > I really have no idea whats going on. . .help? > > -Ivan Ivan, you need to pass the

Python & firewall control (Win32)

2005-06-16 Thread Tim Williams
oogle is not my friend in this instance. TIA Tim -- http://mail.python.org/mailman/listinfo/python-list

Re: "also" to balance "else" ?

2005-06-16 Thread Tim Roberts
Nicolas Fleury <[EMAIL PROTECTED]> wrote: > >But the feature is already there: > >for x in : > BLOCK1 > if : > ALSO-BLOCK > break >else: > BLOCK2 I've been using Python for 8 years. I never knew that feature was in t

Re: Python & firewall control (Win32)

2005-06-17 Thread Tim Williams
On Thu, 16 Jun 2005, Tim Williams wrote: > Does anyone know of (personal/desktop) firewall that can be controlled > via Python, or a Python Firewall package, or even something like DAXFi > but not dormant ? http://wipfw.sourceforge.net/ import os def deny(src, dst, proto="all&qu

Re: Python & firewall control (Win32)

2005-06-17 Thread Tim Williams
> - Original Message - > From: "Tom Anderson" <[EMAIL PROTECTED]> > > > > > AIUI, you won't be stopping and restarting ipfw - the ipfw command just > > modifies the ruleset being used by a continuously-running instance of the > > ipfw kernel module or daemon or whatever. How long it takes

Re: smtplib and TLS

2005-06-18 Thread Tim Williams
- Original Message - From: "Paul Rubin" "http://phr.cx"@NOSPAM.invalid > "Matthias Kluwe" <[EMAIL PROTECTED]> writes: > > Hmm. I tried > > > > server.sock.realsock.shutdown(2) > > before server.quit() with the result of > > I don't think that's exactly what you want. You need to send a

Re: Loop until condition is true

2005-06-18 Thread Tim Williams
- Original Message - From: "Remi Villatel" <[EMAIL PROTECTED]> > There is always a "nice" way to do things in Python but this time I can't > find one. > So far, all I got is: > > while True: > some(code) > if final_condition is True: > break > # > # > > What I don't find so "nice" is t

Re: Is PEP-8 a Code or More of a Guideline?

2007-05-31 Thread Tim Roberts
y make the parser more complicated, because it could no longer be context-insensitive. For example, if I had identifiers called "mine" and "not mine", how would it parse this: if not mine: -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Embed text document in excel application using python

2007-06-01 Thread Tim Golden
[EMAIL PROTECTED] wrote: > Hi, > > How to embed object in excel using python? Is it me, or is this a popular question at the moment? Have a look at this post from yesterday: http://tinyurl.com/37egtt (Doesn't exactly answer, but at least points the way) TJG -- http://mail.python.org/mailman/l

[ANN]: 'twander' Cross-Platform File Manager Version 3.224 Released And Available

2007-06-01 Thread Tim Daneliuk
'twander' Version 3.224 is now released and available for download at: http://www.tundraware.com/Software/twander The last public release was 3.210. This release fixes a number of bugs and adds a variety of useful new features. See the WHATSNEW.txt file for all the details. -

Re: Trouble killing a process on windows

2007-06-02 Thread Tim Golden
Thomas Nelson wrote: > from subprocess import Popen > from time import sleep > import win32api > war3game = Popen(["C:\Program Files\Warcraft III\Frozen Throne.exe"]) > sleep(30) > print "slept for 30" > print win32api.TerminateProcess(int(war3game._handle),-1) > #print > ctypes.windll.kernel32.Te

[Fwd: Re: Trouble killing a process on windows]

2007-06-02 Thread Tim Golden
Tim Golden wrote: > Thomas Nelson wrote: [... re problem Terminating process ...] >> File "C:\Python24\warcraft\runwar3.py", line 7, in ? >> print win32api.TerminateProcess(int(war3game._handle),-1) >> error: (5, 'TerminateProcess', 'Access is

Re: Python 2.3 ODBC Datetime limitations

2007-06-02 Thread Tim Golden
Steve Holden wrote: > YuePing Lu wrote: >> Hello, >> >> Has any of you ever used Python odbc to retrieve data from a relational DB? >> >> I encountered a problem where it can't handle datetime _earlier than >> _*1969*, and _later than _*2040*. It just returned some garbage strings >> when I call

Re: Need help! win32 com_error 'Exception occurred'

2007-06-02 Thread Tim Roberts
R. Seriously, what on earth did you expect this to do? Its whole purpose is send sounds to the sound driver. If there is no sound driver, what was it supposed to do with the audio data? -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Trouble killing a process on windows

2007-06-03 Thread Tim Golden
Thomas Nelson wrote: [... re Access Denied error on trying to TerminateProcess ...] [Tim Golden] >> I suppose you might have to adjust your token privs to include, >> say the Debug priv. This is designed to let you take control >> of any process (and terminate it, or what

Re: monitoring the filesystem for changes

2007-06-03 Thread Tim Golden
rohit wrote: > hello > well in my implementation of readdirectorychangesw i am using > threading that is multiple programs run simultaneously each program > monitoring one drive for changes. > is their a way around this...one program for all drives? > thanks You could use the ReadDirectoryChangesW

Re: Python 3000: Standard API for archives?

2007-06-04 Thread Tim Golden
Chuck Rhode wrote: > samwyse wrote this on Mon, 04 Jun 2007 12:02:03 +. My reply is > below. > >> I think it would be a good thing if a standardized interface >> existed, similar to PEP 247. This would make it easier for one >> script to access multiple types of archives, such as RAR, 7-Zip,

Re: Can os.remove followed by os.path.isfile disagree?

2007-06-06 Thread Tim Golden
[EMAIL PROTECTED] wrote: > Can os.path.isfile(x) ever return True after os.remove(x) has > successfully completed? (Windows 2003, Python 2.3) > > We had a couple of failures in a server application that we cannot yet > reproduce in a simple case. Analysis of the code suggests that the > only poss

Re: Can os.remove followed by os.path.isfile disagree?

2007-06-06 Thread Tim Golden
[EMAIL PROTECTED] wrote: > Can os.path.isfile(x) ever return True after os.remove(x) has > successfully completed? (Windows 2003, Python 2.3) As an afterthought, have you tried NTFS auditing, or directory monitoring, such as: http://timgolden.me.uk/python/win32_how_do_i/watch_directory_for_chang

Re: Can os.remove followed by os.path.isfile disagree?

2007-06-06 Thread Tim Daneliuk
[EMAIL PROTECTED] wrote: > > The application is multithreaded so it is possible that another thread > writes to the file between the "remove" and the "isfile", but at the > end of the failure the file is actually not on the filesystem and I > don't believe there is a way that the file could be r

Re: Baffled on Windows.

2007-06-07 Thread Tim Golden
Neil Cerutti wrote: > I have the following Python program: > > import win32com.client > print 'Huh?' # Actually, it says something profain. > > > Running this program with 2.5.1 causes another Python script in > the same directory to be loaded and run (specifically the import > causes it), and a

Re: Minimize Bandwidth

2007-06-08 Thread Tim Golden
Robert Rawlins - Think Blue wrote: > I have a python application that hits a web service on a regular basis to > post a string of CSV log data and I'm looking to minimize the amount of > bandwidth that the application uses to send the log data. > > Is there any way to encode the string into base64

Re: Binary / SOAPpy

2007-06-08 Thread Tim Golden
Robert Rawlins - Think Blue wrote: > I have a WebService call which returns an array, the first element in > that array is the binary for a zip file, however I’m having trouble > writing that binary string into an actual file when it arrives, I’ve > tried the following method. > > Result = call

Re: updating db with csv

2007-06-10 Thread Tim Roberts
UPDATE xxx" that might do what you want. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: read 9 bytes

2007-06-10 Thread Tim Roberts
stance. >If I do: serialport.read(4) >I would get 8 bytes, No. You would get 4 bytes. Do you see documentation to the contrary? -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: The Concepts and Confusions of Prefix, Infix, Postfix and Fully Functional Notations

2007-06-11 Thread Tim Bradshaw
On Jun 11, 8:02 am, Twisted <[EMAIL PROTECTED]> wrote: > On Jun 11, 2:42 am, Joachim Durchholz <[EMAIL PROTECTED]> wrote: > > > It is possible to write maintainable Perl. > > Interesting (spoken in the tone of someone hearing about a purported > sighting of Bigfoot, or maybe a UFO). > I think it's

Re: Problem with following python code

2007-06-11 Thread Tim Leslie
once. I would be greatful if you could help me out. Thanx! > >>> f=1 > >>> for i in range(10,100): You need to switch these two lines to reset the flag each time around the outer loop. Cheers, Tim > ... for j in range(2,i): > ...

Re: file open default location

2007-06-12 Thread Tim Golden
T. Crane wrote: > myFile = file('test.txt','w') > > Here I'm opening/creating a file but I have not specified the exact path, so > how does Python determine where to 'put' this file? More to the point, how > do I change what the default path is? Right now it's a networked drive that > should

Re: updating db with csv

2007-06-12 Thread Tim Roberts
Captain Paralytic <[EMAIL PROTECTED]> wrote: >On 11 Jun, 07:37, Tim Roberts <[EMAIL PROTECTED]> wrote: >| Not in standard SQL. MySQL supports a REPLACE extension that does >| an UPDATE if the key already exists, and an INSERT if it does not. >| There is also an extens

Re: Bytes/File Size Format Function

2007-06-13 Thread Tim Roberts
7;, 'tb','pb', 'eb', 'zb', 'yb'] >[int(log)] >) I have a couple of picky comments. The abbreviation for "bytes" should be "B"; small "b" is bits by convention. All of the prefixes above "k"

Re: MS Word parser

2007-06-13 Thread Tim Golden
[EMAIL PROTECTED] wrote: > Hi all, > I'm currently using antiword to extract content from MS Word files. > Is there another way to do this without relying on any command prompt > application? Well you haven't given your environment, but is there anything to stop you from controlling Word itself vi

Re: Questions about mathematical and statistical functionality in Python

2007-06-14 Thread Tim Churches
of using matplotlib or other Python-based graphics packages for some tasks if we wish). The main thing to remember, though, is that indexing is zero-based in Python and 1-based in R... Tim C -- http://mail.python.org/mailman/listinfo/python-list

Re: Where can I suggest an enchantment for Python Zip lib?

2007-06-14 Thread Tim Roberts
n would be to reduce the priority of your archiving process. Your operating system is far better equipped to share the CPU than you are. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Convert to C/C++?

2007-06-14 Thread Tim Roberts
ringFromGUID to make it printable. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: python i2c ioctl

2007-06-14 Thread Tim Roberts
i2c_fd = i2c_open() if i2c_fd < 0: print "i2c open error" return 1 But, of course, that's not enough either; i2c_fd is a local variable in THIS function as well. You should change ALL of the functions so that they accept an fd as the first parameter, and then pass i2c_fd into the functions here. Alternatively, you could create a wrapper class to hold the fd and make the function methods on that class. >while "azz": >i2c_start () I'm curious. What do you think "while" statement is doing? The answer is that it is an infinite loop; the string "azz" will always be true, so the while statement will always loop. I can't guess what you really wanted here. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: smtp server simulation using Python

2007-06-18 Thread Tim Williams
sending it. Is it possible to extend the DebuggingServer class,and > override the process_message() method to accomplish this? If so, any > suggestions are appreciated. > Search the list archives for SMTPRIG.py :) Tim -- http://mail.python.org/mailman/listinfo/python-list

Re: avoid script running twice

2007-06-18 Thread Tim Williams
the file is already open the script won't run, if the script finshes/crashes or the machine reboots the open file will close. In both cases if the script finishes normally or crashes, or the machine is restarted. The lock (ie socket or open file) is released. HTH :) -- Tim Williams -- http://mail.python.org/mailman/listinfo/python-list

Re: avoid script running twice

2007-06-18 Thread Tim Williams
> I think thats the most hassle free way of doing it. If the script finishes abnormally, the file will still exist and future execution of the script will fail. :) -- Tim Williams -- http://mail.python.org/mailman/listinfo/python-list

IPV6 Fatal Error

2007-06-18 Thread Tim Graber
sable-ipv6". My question is, are we to disable ipv6 in some setup file prior to running ./configure?ifconfig -a6 does not return any output. Any information on getting this setup would be greatly appreciated. Thanks. -- Tim -- http://mail.python.org/mailman/listinfo/python-list

Re: avoid script running twice

2007-06-18 Thread Tim Williams
On 18/06/07, Robin Becker <[EMAIL PROTECTED]> wrote: > Wildemar Wildenburger wrote: > > Robin Becker wrote: > . > > > > Well I can think of a dumb way: create a temporary file during the > > transaction and have your script check for that before running its main > > body. > > > > > > I thin

Re: avoid script running twice

2007-06-18 Thread Tim Williams
On 18/06/07, Nick Craig-Wood <[EMAIL PROTECTED]> wrote: > Tim Williams <[EMAIL PROTECTED]> wrote: > > You can also do this by holding a file open in write mode until the > > script has finished. > > > >try: > > open('lock.txt&

Re: GUI apps in Windows with native widgets?

2007-06-18 Thread Tim Roberts
e with the Win32 API and MFC, pywin32 includes a relatively thin wrapper around MFC. It's quite possible to write GUI apps using it, and there are several good examples. I'm not sure that I'd prefer it to wxPython, however. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: Invisible processes in Win2K

2007-06-21 Thread Tim Golden
[EMAIL PROTECTED] wrote: > I'm running a Python program on M$ Windows 2000 as a test monitor. The > program > should close various processes, mostly "Application error"-windows, as they > are > created. This works fine until the screensaver gets active or until I press > Ctrl-Alt-Del and choos

Re: The Modernization of Emacs: terminology buffer and keybinding

2007-06-22 Thread Tim Roberts
Bjorn Borud <[EMAIL PROTECTED]> wrote: > >bah, UNIX is not user hostile; it is just selective about its >friends. Right. My favorite Unix quote is from the same source (Dennis Ritchie): Unix is the answer. You just have to phrase the question very carefully. -- Tim

Re: The Modernization of Emacs: terminology buffer and keybinding

2007-06-22 Thread Tim Roberts
h have our own favorite brand, and nothing you say will convince me to change mine. Editor, that is. I do occasionally change my underwear. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

pypdf assert error on documentinfo

2007-06-28 Thread Tim Arnold
Using pyPdf, nice user interface. Maybe it doesn't handle pdf 1.4? I'm getting an assertion error from the following code. The pdf file shows it does have a title in its document info (using acrobat 8 or reader 5). pdf is version 1.4, produced with pdfeTex (pdflatex) 1.304 using python 2.4.1 #=

Re: The Modernization of Emacs: terminology buffer and keybinding

2007-06-28 Thread Tim Roberts
pt last in 1998. The current installer is as painless as most open source installers are. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: glob.glob standardization

2007-06-28 Thread Tim Roberts
ike os.listdir do? Martin gave you the real answer, but you should realize that your analysis of the behavior is faulty. In EACH case, glob.glob has returned all of the names that exactly match your pattern. It's not about absolute or relative. For example, if you do glob.glob( '.

ann: Python at the IET

2007-07-02 Thread Tim Golden
& coffee beforehand and sandwiches afterwards. Tim Golden [1] http://www.theiet.org/ [2] http://www.iee.org/OnComms/Branches/UK/england/SEastE/london/Venues/savoy.cfm [3] http://www.iee.org/OnComms/Branches/UK/england/SEastE/london/Events/july.cfm -- http://mail.python.org/mailman/listinfo/python-list

Re: How can i change an Object type ?

2007-07-03 Thread Tim Roberts
ribute "Smart" is not >available >Error MEssage: >AttributeError: 'instance at 0x30216960>' object has no attribute 'Smart' Smart is part of IITUserPlaylist, not IITPlaylist. You need to call curPlaylist.QueryInterface to get the IITUserPlaylist, but that

Re: Which Python Version

2007-07-04 Thread Tim Golden
Robert Rawlins - Think Blue wrote: > Is there a command I can run to confirm which version of python I'm running? From outside Python: python -V (that's a capital V) From inside Python: import sys print sys.version (and a couple of more easily parseable alternatives; look at the sy

Re: what is wrong with that r"\"

2007-07-05 Thread Tim Roberts
a\'"- > >So as long as your regex does not use all the valid characters, readability is >maintained. But what about my program that wants to use r_a_b_ as an identifier? -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: what is wrong with that r"\"

2007-07-07 Thread Tim Roberts
>original meaning... sed can do that because its commands are one character long. Whatever follows an "s" must a delimiter because it can't be anything else. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Pythonic cats (and dogs?)

2007-07-09 Thread Tim Churches
A challenge: an elegant, parsimonious and more general[1] implementation of this, in Python: http://lol.ianloic.com/feed/www.planetpython.org/rss20.xml Tim C [1] Dogs, ponies, babies, politicians... -- http://mail.python.org/mailman/listinfo/python-list

Re: S2K DTS and Python

2007-07-10 Thread Tim Golden
Phil Runciman wrote: > I am a Python newbie so please be gentle on me. Welcome to Python. > I have created a program that takes text files within a directory and it > successfully parses the information from them to create 3 CSV files. Good so far. > However, I now want to update some tables in

Re: 2**2**2**2**2 wrong? Bug?

2007-07-16 Thread Tim Roberts
"Jim Langston" <[EMAIL PROTECTED]> wrote: > >Gah! Python goes right to left? Dang, I haven't seen that since APL. No, *exponentiation* in Python goes right to left, as it does in all the languages I've used that support an exponentiation operator. -- Tim Rober

Re: Copy List

2007-07-18 Thread Tim Williams
On 18/07/07, Robert Rawlins - Think Blue <[EMAIL PROTECTED]> wrote: > > What's the best way to create a copy of a list? I've seen several method and > I'm not sure what to use. This will be in a class and one method creates a > list which I then want to move to the self scope, like so: > listB =

Re: how to implementation latent semantic indexing in python..

2007-07-18 Thread Tim Churches
untry, but the inventor still needs to file patent applications and have them approved (sealed) is each and every country. Did Bellcore do that back in the 1980s? Tim C -- http://mail.python.org/mailman/listinfo/python-list

Re: how to implementation latent semantic indexing in python..

2007-07-18 Thread Tim Churches
Alex Martelli wrote: > Tim Churches <[EMAIL PROTECTED]> wrote: > >> malkarouri wrote: >>> On 13 Jul, 17:18, 78ncp <[EMAIL PROTECTED]> wrote: >>>> hi... >>>> how to implementation algorithm latent semantic indexing in python >>>&

Re: odbc module for python

2007-07-19 Thread Tim Golden
Steve Holden wrote: > Sean Davis wrote: >> What are the alternatives for accessing an ODBC source from python >> (linux 64-bit, python 2.5)? It looks like mxODBC is the only one >> available? >> > There is, I understand, a pyodbc module as well. Having never used it I > can't say how good it is.

Re: Gmail Error using smtplib

2007-07-20 Thread Tim Williams
On 20/07/07, DJ Fadereu <[EMAIL PROTECTED]> wrote: > Hello, can anyone help me with this? What am I doing wrong here? > > (I've changed private info to /xx) > I'm getting an authentication error while using a standard script > Gmail: > --SCRIPT--

Re: PY shutil on win xp home version

2007-04-18 Thread Tim Golden
jim-on-linux wrote: > python help, > > A client is using win xp home. > > my program contains; >shutil.copyfile(n, 'prn') > > This runs fine on win xp pro but they are getting > the following traceback. > > File "LOP_PRT_10.pyc", line 170, in __init__ > File "LOP_PRT_10.pyc", line 188,

Re: How to communicate via USB "port"

2007-04-18 Thread Tim Roberts
he device to send before you can talk to it. On the other hand, as someone else pointed out, many types of USB devices fall into standard device classes, and the operating system supplies drivers for those classes. If your GPS device is in the communication class, you might be able to pretend

Re: Helpbook and CHM

2007-04-19 Thread Tim Golden
Teja wrote: > how to generate CHM files in Boa(Python)??? http://www.rutherfurd.net/software/rst2chm/index.html TJG -- http://mail.python.org/mailman/listinfo/python-list

Re: Byte-Array to String

2007-04-19 Thread Tim Golden
Robert Rawlins - Think Blue wrote: > I have a byte array passed to me by dbus and I'm looking to convert it into > a string? Is that possible? Sorry for seeming like a putts with these > questions, I'm not used to all these complex data types :-D > > dbus.Array([dbus.Byte(54), dbus.Byte(0), dbus.B

Re: Byte-Array to String

2007-04-19 Thread Tim Golden
Robert Rawlins - Think Blue wrote: [... snip ...] > The first method, when I print its results just gives me > dbus.Array([dbus.UInt32(65547L)], signature=dbus.Signature('u')) the method > gives me that byte array and the third doesn't appear to work at all :-D > > Unfortunately nowhere seems to

Re: PY shutil on win xp home version

2007-04-20 Thread Tim Golden
jim-on-linux wrote: > On Wednesday 18 April 2007 17:02, Tim Golden > wrote: >> jim-on-linux wrote: >>> python help, >>> >>> A client is using win xp home. >>> >>> my program contains; >>>shutil.copyfile(n, 'prn')

Re: CGI Script using Python

2007-04-21 Thread Tim Roberts
download files to the client browser, but the user will have to be involved to tell the browser where to store the incoming file. Doing anything else would be a security hole. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: python cgi problem with textarea

2007-04-23 Thread Tim Roberts
as long as the textarea input has no spaces. > >it doest work because the "space" character isnt interpreted >correctly, you need to change the space characters too   What??? Did you even read the problem description? -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: MS SQL Server Extension?

2007-04-25 Thread Tim Golden
Jack wrote: > Hi all, in my next project, my Python code needs to talk to an MS SQL > 2000 Server. Internet search gives me http://pymssql.sourceforge.net/ > I wonder what module(s) people are using. My code runs on a Linux > box so the module has to build on Linux. Any hints/pointers are welcome.

Re: Tutorial creates confusion about slices

2007-04-25 Thread Tim Golden
Antoon Pardon wrote: > On 2007-04-24, Michael Hoffman <[EMAIL PROTECTED]> wrote: > >> Really only one person has argued that the docs do not need to be >> changed. The other two people seemed to think you were asking for help >> rather than discussing how to revise the docs. Understandable, sinc

Re: Now()

2007-04-25 Thread Tim Golden
Robert Rawlins - Think Blue wrote: > I'm using the following function 'str (now)' to place a date time stamp into > a log file, which works fine, however it writes the stamp like this. > 2007-04-25 11:06:53.873029 > But I need to expel those extra decimal places as they're causing problems > wit

Re: Simple sqlite3 question

2007-04-25 Thread Tim Roberts
but if you had used "testdata" as the filename, it would have failed. You should use one of these alternatives: conn = sqlite3.connect('.\\optiondata') conn = sqlite3.connect(r'.\optiondata') conn = sqlite3.connect('./optiondata') conn = sqlite3.connect(

Re: Accessing SQL View with Python

2007-04-27 Thread Tim Golden
[EMAIL PROTECTED] wrote: > Hi All, > > I need to access a Microsoft SQL database View. Is there a way to do > this with Python? I have done a fair share of "googling" and found > nothing on accessing Views, just executing SQL, which I already know > how to do. > > I am running Windows XP, Python

Re: Dedicated CPU core for Python?

2007-04-27 Thread Tim Roberts
the resources. Except for specific needs in some drivers, the use of CPU and thread affinity is virtually never a good idea. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

Re: I have a chance to do somting diffrent way not Python ?!

2007-04-29 Thread Tim Roberts
e several very good Unix-derived shells available for Windows. UnxUtils includes a bash and a zsh. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list

<    35   36   37   38   39   40   41   42   43   44   >