NovelSpace Media, LLC announces the launch of their new online bookstore and web portal devoted to developers and programmers.

2006-05-13 Thread paquejd
NovelSpace Media, LLC has announced the launch of its new online bookstore, NovelSpace.com. Located at http://www.novelspace.com, it features a wide and varied selection of books for computer aficionados, developers, software engineers, and programmers. In addition to low prices and shipping

Re: distributing a app frozen by cx_freeze

2006-05-13 Thread Carl Banks
Flavio wrote: Traceback (most recent call last): File /home/fccoelho/Downloads/cx_Freeze-3.0.2/initscripts/Console.py, line 26, in ? File epigrass.py, line 4, in ? ImportError: /home/flavio/freeze/qt.so: undefined symbol: _ZNK9QSGIStyle9classNameEv It is looking for the Original

Tail Call Optimization Decorator?

2006-05-13 Thread Casey Hawthorne
Tail Call Optimization and Recursion are separate concepts! -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Amazing offers for Computers,Laptops

2006-05-13 Thread [EMAIL PROTECTED]
Hy every one. An amazing opportunity for all the people to buy and get all the information related to the Laptops, Computer Systems, registration for free trail and for rental basis. Effort less thing, just make look over www.eazyrentals.com --

Re: distributing a app frozen by cx_freeze

2006-05-13 Thread Flavio
Thanks for the hint. I'll try to get cx_freeze to bundle up other shared libraries it may not be bundling such as qtcanvas, qtext, qtui, etc. and see if it works. I'll post back the results to help other poor souls like me. Thanks -- http://mail.python.org/mailman/listinfo/python-list

Slovenian Python User Group

2006-05-13 Thread Sebastjan Trepca
Hi! just wanted to send a notice about a new portal/group for Slovenian Python fans here :) http://soup.zen.si (btw, it's in slovene lang) Sebastjan -- http://mail.python.org/mailman/listinfo/python-list

Re: A critic of Guido's blog on Python's lambda

2006-05-13 Thread Duane Rettig
Alexander Schmolck [EMAIL PROTECTED] writes: I think that in most contexts lexical transparency is desirable so that deviations from lexical transparency ought to be well motivated. I also believe that a construct that is usually used to establish a lexically transparent binding shouldn't be

plot data from Excel sheet by Matplotlib, how?

2006-05-13 Thread N/A
Hi all, Can any1 please guide me how to plot data from Excel by Matplotlib? Let's say, I have 78(rows) x 8(cols) data in an Excel sheet. I would like to plot data for all 78(rows) at 4th column against data for all 78(rows) at 7th column. How to plot it? Thank u! --

Sending mail with attachment...

2006-05-13 Thread Merrigan
Hi, I have now eventually finished my newbie-backup script and I'm very proud of the way it functions... Anyways, I am looking for an easy way to use smtplib to send an email with the output log of the script to multiple accounts. I need to use it with a smtp server, and cannot pipe it directly

Re: getting rid of pass

2006-05-13 Thread Bruno Desthuilliers
David Murmann a écrit : Hi all! i just had this crazy idea: instead of while cond(): pass write while cond(). Yuck or try: import xyz except ImportError: pass compared to try: import xyz except ImportError. Yuck again i don't know whether this is

Re: compiling module from string and put into namespace

2006-05-13 Thread Bruno Desthuilliers
glomde a écrit : Tanks but that isn't what I am looking for. I really want a function that you can call and imports the module into the calling functions namespace. Please read the documentation of the __import__() *function*. (notice the double leading and ending underscores and the

Is it possible to set the date/time of a directory in windows with Python? If so how?

2006-05-13 Thread ToddLMorgan
I'm trying to set any of the dates (create, modification, access) of a directory under windows with python. I'm trying to do this as I'm trying to write a unittest for a directory cleaning script I'm writing (ie I need the test to set the create/mod time for some of the directories so that I can

Re: Is it possible to set the date/time of a directory in windows with Python? If so how?

2006-05-13 Thread Roger Upole
ToddLMorgan [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I'm trying to set any of the dates (create, modification, access) of a directory under windows with python. I'm trying to do this as I'm trying to write a unittest for a directory cleaning script I'm writing (ie I need the

Named regexp variables, an extension proposal.

2006-05-13 Thread Paddy
Proposal: Named RE variables == The problem I have is that I am writing a 'good-enough' verilog tag extractor as a long regular expression (with the 'x' flag for readability), and find myself both 1) Repeating sections of the RE, and 2) Wanting to add '(?Psome_clarifier...)

Re: How to install pyTrix?

2006-05-13 Thread Claudio Grondi
DeepBlue wrote: Hi all, can any1 please tell me how to install pyTrix? thx! The first step should be to get it, but how can it be got? Claudio -- http://mail.python.org/mailman/listinfo/python-list

Re: Sending mail with attachment...

2006-05-13 Thread Merrigan
Hi Guys, I just wanted to post the error, and then also the coda that causes itI get this no matter what I do to this, and I don't understand it. Any help would be welcome. Thank you Error :: Traceback (most recent call last): File /home/merrigan/projects/Backup Script/hobbitarchive.py,

Re: A critic of Guido's blog on Python's lambda

2006-05-13 Thread Marcin 'Qrczak' Kowalczyk
Ken Tilton [EMAIL PROTECTED] writes: I think the point is that, with the variable actually being just a string and with dedicated new explicit functions required as accessors, well, you could hack that up in any language with dictionaries. It is the beginnings of an interpreter, not Python

SystemError: ... cellobject.c:22: bad argument to internal ?

2006-05-13 Thread robert
From the trace of a 2.3.5 software i got: \'SystemError: C:sfpythondist23srcObjectscellobject.c:22: bad argument to internal function\\n\'] from the middle of normal function / or its call. What is this? There is:

Re: A critic of Guido's blog on Python's lambda

2006-05-13 Thread Marcin 'Qrczak' Kowalczyk
Alexander Schmolck [EMAIL PROTECTED] writes: I'd like to see a demonstration that using the same binding syntax for special and lexical variables buys you something apart from bugs. There are 3 fundamental operations related to plain mutable variables: A1. Making a new mutable variable with

Re: where do you run database scripts/where are DBs 'located'?

2006-05-13 Thread BartlebyScrivener
John, Yep, different module. I'll watch the thread. Perhaps once you get connected, we should make a mini-HOWTO for XP users while it's fresh in your mind, because this question seems to come up a lot, and beginners would probably appreciate a short howto that would perhaps detail how to set up

Re: where do you run database scripts/where are DBs 'located'?

2006-05-13 Thread BartlebyScrivener
driv=bbdatabank Oops, sorry, I meant, driv='DSN=bbdatabank' rick -- http://mail.python.org/mailman/listinfo/python-list

Re: Named regexp variables, an extension proposal.

2006-05-13 Thread John Machin
On 13/05/2006 7:39 PM, Paddy wrote: [snip] Extension; named RE variables, with arguments === In this, all group definitions in the body of the variable definition reference the literal contents of groups appearing after the variable name, (but within the

Re: Is it possible to set the date/time of a directory in windows with Python? If so how?

2006-05-13 Thread ToddLMorgan
Thanks very much for that roger :-) I changed my code to filehandle = win32file.CreateFile(file, win32file.GENERIC_WRITE, win32file.FILE_SHARE_WRITE, None, win32con.OPEN_ALWAYS, win32con.FILE_FLAG_BACKUP_SEMANTICS, None) nowWin32=pywintypes.Time(theTime)

Re: Tkinter: ability to delete widgets from Text and then re-add them

2006-05-13 Thread nholtz
I now see that I can accomplish what I want using the Canvas widget, instead of the Text widget (I.e., I can create a window on it, delete the window, then re add it without recreating the underlying widget object). As I don't want the raw contents user-editable, I guess its better to use a

Re: Sending mail with attachment...

2006-05-13 Thread Tim Williams
On 13 May 2006 03:13:33 -0700, Merrigan [EMAIL PROTECTED] wrote: :: Code :: def mailSender(): openlogmsg = open(completelog, 'rb') mesg = MIMEText(openlogmsg.read()) openlogmsg.close() mesg['Subject'] = subject mesg['From'] = fromaddy

Re: reusing parts of a string in RE matches?

2006-05-13 Thread Mirco Wahab
Hi Fredrik you brought up some terse and somehow expressive lines with their own beauty ... [this] is best done by a list comprehension: l = [m[1] for m in re.findall(r, t)] or, [...] a generator expression: g = (m[1] for m in re.findall(r, t)) or process(m[1] for m in

Re: python soap web services

2006-05-13 Thread Butternut squash
Diez B. Roggisch wrote: Butternut squash wrote: Is there any reason why there isn't any python library that makes using soap as easy as how microsoft .net makes it. I mean I write rudimentary asmx files call them from a webbrowser. The WSDL is generated and then there is documentation

Re: Sending mail with attachment...

2006-05-13 Thread [EMAIL PROTECTED]
Replace: mesg['To'] = recievelist By: mesg['To'] = ', '.join(recievelist) -- http://mail.python.org/mailman/listinfo/python-list

Re: How to pass variables between scripts

2006-05-13 Thread Jonathan Smith
Gross, Dorit (SDRN) wrote: [snip] for f in fileList: try: globvars = {'infile' : f} locvars = {} execfile('/scripts/second.py', globvars(), locvars) except IOError: exit(0) print locvars

Package that imports with name of dependent package

2006-05-13 Thread David Pratt
Hi. I have code that currently depends on a particular package of a framework. I have decided I want to create my own package because I have made many changes and it is getting too difficult to maintain each time I retrieve an updated version of the framework from svn. The problem is, that

Re: python rounding problem.

2006-05-13 Thread Florian Diesch
Thomas Bartkus [EMAIL PROTECTED] wrote: Grant Edwards [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On 2006-05-08, Thomas Bartkus [EMAIL PROTECTED] wrote: does python support true rations, which means that 1/3 is a true one-third and not 0.3 rounded off at some

Re: Package that imports with name of dependent package

2006-05-13 Thread Maric Michaud
Le Samedi 13 Mai 2006 16:05, David Pratt a écrit : I'd appreciate hearing of what I can do in an __init__ file or what other strategy could make this work. Many thanks. you should leave the original package intact and patch it with new mehod and moddule; for example (A is the original package):

Re: Package that imports with name of dependent package

2006-05-13 Thread Peter Otten
David Pratt wrote: Hi. I have code that currently depends on a particular package of a framework. I have decided I want to create my own package because I have made many changes and it is getting too difficult to maintain each time I retrieve an updated version of the framework from svn.

Re: distributing a app frozen by cx_freeze

2006-05-13 Thread Flavio
Well I managed to get rid of the undefined symbol message by copying all qt libs to the freeze directory, the problem is that now the package is huge (83MB)! So my question is: is there a way to find out exactly which lib is missing ? Thanks --

Unicode ZSI interaction ??

2006-05-13 Thread Joakim Hove
Dear newsgroup, I have written a cgi script in Python, and it has worked fine for some time. Now the installed Python version has been upgraded to 2.4.1 and I am having problems with non ascii characters. The core of the problem I have is as follows: 1. The webpage contains a text field

Re: where do you run database scripts/where are DBs 'located'?

2006-05-13 Thread Lou Losee
On 5/13/06, Dennis Lee Bieber [EMAIL PROTECTED] wrote: On Fri, 12 May 2006 21:00:49 -0400, John Salerno[EMAIL PROTECTED] declaimed the following in comp.lang.python: Latest development: I turned off my firewall and it worked. :) Next step -- figure out what rule you need to define to the

Re: Package that imports with name of dependent package

2006-05-13 Thread Peter Otten
Peter Otten wrote: I'd appreciate hearing of what I can do in an __init__ file or what other strategy could make this work. Many thanks. I think fixing the imports is the better long-term approach. But putting from pkgutil import extend_path import mypackage __path__ =

Re: Package that imports with name of dependent package

2006-05-13 Thread David Pratt
Hi Peter. I'd like to fix the imports, but this would impact the portability of portions of the code that currently work with the existing package from the framework. This solution does the trick and allows me to create the package I want using a good amount of new material. I don't have to

Re: Named regexp variables, an extension proposal.

2006-05-13 Thread Paul McGuire
Paddy [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Proposal: Named RE variables == The problem I have is that I am writing a 'good-enough' verilog tag extractor as a long regular expression (with the 'x' flag for readability), and find myself both 1)

Factory pressed dvd movies, ps2, psp xbox backups for sale !!!

2006-05-13 Thread yuna77
We're offering all the latest factory pressed high quality dvd movies, ps2, psp and xbox silvers with factory printed colour inserts at fantastic prices, whether for personal use or reselling. We're shipping worldwide with various shipping methods. For resellers, please contact us for bulk

Re: Package that imports with name of dependent package

2006-05-13 Thread David Pratt
Hi Peter. Thank you for this warning. I'll document this in the code. I plan on importing only from dependentpackage for portability. Also, much in the framework relies upon it. This approach is primarily for maintenance purposes and would also allow me to package the modified dependentpackage

Re: Slovenian Python User Group

2006-05-13 Thread [EMAIL PROTECTED]
Sebastjan Trepca wrote: Hi! just wanted to send a notice about a new portal/group for Slovenian Python fans here :) http://soup.zen.si (btw, it's in slovene lang) But why is SOUP (Slovenski Ortodoksni Uporabniki Pythona) used as an acronym? Or is SOUP a word in Slovene also?

PyX on Windows

2006-05-13 Thread Tom Longridge
Hi, I'm trying to use PyX to draw some diagrams with text in. I want to change the font, so need to change the text mode from TeX to LaTeX. However I get an error when I do so: pyx.text.TexResultError: unhandled TeX response (might be an error) The expression passed to TeX was:

Setting up InformixDb

2006-05-13 Thread The Shaffer s
I have an informix database on a unix machine which I want to access. I downloaded InformixDb-2.2 and managed to get it built and installed and it works fine with python. My problem is I want to access the same database from a PC remotely. Yes, I already have informix setup and configured on the

Re: problemi con POST

2006-05-13 Thread Alex Martelli
Heavy [EMAIL PROTECTED] wrote: Sorry, you got reason, I thought I can write in my language, cause this is the first time that I post a question in this group... My problem is that I have to receive parameters from a POST method, i try to read them from the socket 'rfile', but this action is

Re: compiling module from string and put into namespace

2006-05-13 Thread glomde
I dont want the caller to call import but a function. come again? type (__builtins__.__import__) type 'builtin_function_or_method' I didnt mean that __import__ isnt a function, but that I want to make a function called ImoprtFile that actually does something very similar that what

Re: where do you run database scripts/where are DBs 'located'?

2006-05-13 Thread John Salerno
Dennis Lee Bieber wrote: On Fri, 12 May 2006 21:00:49 -0400, John Salerno [EMAIL PROTECTED] declaimed the following in comp.lang.python: Latest development: I turned off my firewall and it worked. :) Next step -- figure out what rule you need to define to the firewall to permit it

Re: where do you run database scripts/where are DBs 'located'?

2006-05-13 Thread John Salerno
BartlebyScrivener wrote: John, Yep, different module. I'll watch the thread. Perhaps once you get connected, we should make a mini-HOWTO for XP users while it's fresh in your mind, because this question seems to come up a lot, and beginners would probably appreciate a short howto that

Re: Sending mail with attachment...

2006-05-13 Thread John Salerno
Merrigan wrote: mesg['To'] = recievelist It's already been pointed out that this is a problem, but I just wanted to mention also that 'recieve' is misspelled, in case that affects anything, or others who might read/use the code. -- http://mail.python.org/mailman/listinfo/python-list

Re: where do you run database scripts/where are DBs 'located'?

2006-05-13 Thread BartlebyScrivener
But with the firewall off, everything seems to work fine. Whatever works. But I'm having trouble imagining how a firewall would interfere with you accessing your own db on localhost. -- http://mail.python.org/mailman/listinfo/python-list

Re: compiling module from string and put into namespace

2006-05-13 Thread glomde
Ok, now I think I know what I need to do. I need to create a variable in the calling functions locals. So how do I get access to the calles locals dictionary? Is it possible? -- http://mail.python.org/mailman/listinfo/python-list

Re: SystemError: ... cellobject.c:22: bad argument to internal ?

2006-05-13 Thread [EMAIL PROTECTED]
robert wrote: From the trace of a 2.3.5 software i got: \'SystemError: C:sfpythondist23srcObjectscellobject.c:22: bad argument to internal function\\n\'] ... Will there be another bug-fix release of Python 2.3 ? No, is this still a problem in 2.4? 2.4.4 is

Re: compiling module from string and put into namespace

2006-05-13 Thread Edward Elliott
glomde wrote: I didnt mean that __import__ isnt a function, but that I want to make a function called ImoprtFile that actually does something very similar that what __import__. So to rephrsase the questin how does __import__ load a module into the callers namespace. Ok got it now. I'm

Re: distributing a app frozen by cx_freeze

2006-05-13 Thread Carl Banks
Flavio wrote: Well I managed to get rid of the undefined symbol message by copying all qt libs to the freeze directory, the problem is that now the package is huge (83MB)! So my question is: is there a way to find out exactly which lib is missing ? You know, if you're doing this on Linux,

Re: where do you run database scripts/where are DBs 'located'?

2006-05-13 Thread John Salerno
BartlebyScrivener wrote: But with the firewall off, everything seems to work fine. Whatever works. But I'm having trouble imagining how a firewall would interfere with you accessing your own db on localhost. I don't know either. Something to do with the ports it's trying to use I guess.

[ANN] PanDAV on SourceForge.net

2006-05-13 Thread Ivan Voras
Around three weeks ago there was a thread about Python WebDAV servers, and I mentioned my PanDAV work (old homepage: http://ivoras.sharanet.org/projects/pandav.html). There was some interest in continuing the development and merging patches made by its users, so I requested a SourceForge

Re: Slow network reading?

2006-05-13 Thread Andrew MacIntyre
Ivan Voras wrote: Andrew MacIntyre wrote: Comparative CPU memory utilisation statistics, not to mention platform and version of Python, would be useful hints... During benchmarking, all versions cause all CPU to be used, but Python version has ~1.5x more CPU time allocated to it than

Re: compiling module from string and put into namespace

2006-05-13 Thread Fuzzyman
glomde wrote: Ok, now I think I know what I need to do. I need to create a variable in the calling functions locals. So how do I get access to the calles locals dictionary? Is it possible? If your import is used in the current namespace, just use the global keyword. Best is if your function

Re: unzip zip files

2006-05-13 Thread Jay Parlar
On May 12, 2006, at 5:45 PM, DataSmash wrote: I need to unzip all zip file(s) in the current directory into their own subdirectories. The zip file name(s) always start with the string usa and end with .zip. The code below will make the subdirectory, move the zip file into the subdirectory,

Re: Slow network reading?

2006-05-13 Thread Ivan Voras
Andrew MacIntyre wrote: That's only because I need the .readline() function. In C, I'm using fgets() (with the expectation that iostream will buffer data). The readline method of the file object lookalike returned by makefile implements all of the line splitting logic in Python code, which

Re: Setting up InformixDb

2006-05-13 Thread Carsten Haese
On Sat, 13 May 2006 14:09:19 -0400, The Shaffer s wrote I have an informix database on a unix machine which I want to access. I downloaded InformixDb-2.2 and managed to get it built and installed and it works fine with python. My problem is I want to access the same database from a PC

Iterating generator from C

2006-05-13 Thread Sven Suursoho
Hi, I am working on project that has embedded python interpreter to run user-specified python procedures. Those procedures might return any iterable object with set of result data -- basically everything for which iter() returns valid object (list, tuple, dict, iterator etc) It works ok,

LocaWapp 09 - localhost web applications

2006-05-13 Thread .
http://daviderognoni.blogspot.com?locawapp - MAIN NEWS === * add thread * add Request object * new locawapp_main function * fixed files.py * ... http://daviderognoni.blogspot.com?locawapp -- http://mail.python.org/mailman/listinfo/python-list

Re: distributing a app frozen by cx_freeze

2006-05-13 Thread Flavio
I know, but the whole point of cx_freeze is to generate standalone executables, so asking for an installation of an specific version of Qt is just a little better than asking the end user to install from source... -- http://mail.python.org/mailman/listinfo/python-list

retain values between fun calls

2006-05-13 Thread Gary Wessle
Hi the second argument in the functions below suppose to retain its value between function calls, the first does, the second does not and I would like to know why it doesn't? and how to make it so it does? thanks # it does def f(a, L=[]): L.append(a) return L print f('a') print f('b')

cx_freeze and matplotlib

2006-05-13 Thread Flavio
I am trying to freeze an application which imports matplotlib. It all works fine on the machine where it was frozen. The executable runs without a glitch. But when I move the directory containing the frozen executable and other libs to a new machine, I get the following error: Traceback (most

Cellular automata and image manipulation

2006-05-13 Thread defcon8
Hello. I have recently been experimenting with cellular automata and I would like to know how I could convert a 2d list of 0's and 1's into white and black squares on an image. I have tried to install matplotlib and also NumTut but both to no avail. There seem to be bugs in their installation and

Re: Cellular automata and image manipulation

2006-05-13 Thread Robert Kern
[EMAIL PROTECTED] wrote: Hello. I have recently been experimenting with cellular automata and I would like to know how I could convert a 2d list of 0's and 1's into white and black squares on an image. I have tried to install matplotlib and also NumTut but both to no avail. There seem to be

Re: distributing a app frozen by cx_freeze

2006-05-13 Thread Edward Elliott
Flavio wrote: ImportError: /home/flavio/freeze/qt.so: undefined symbol: _ZNK9QSGIStyle9classNameEv So my question is: is there a way to find out exactly which lib is missing ? yes - find the one with that symbol. wash, rinse, repeat. ;) -- Edward Elliott UC Berkeley School of Law (Boalt

Re: Cellular automata and image manipulation

2006-05-13 Thread John Bauman
[EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hello. I have recently been experimenting with cellular automata and I would like to know how I could convert a 2d list of 0's and 1's into white and black squares on an image. I have tried to install matplotlib and also NumTut but

distutils and binding a script to a file extension on windows

2006-05-13 Thread Alexandre Guimond
Hi. I built a little installer on windows XP using distutils for my package. In there i add a few files to the python script directory. I would like one of these scripts to be the default program to be used by files with a given extention (e.g. i have an image viewer and would like it to be used

Re: having trouble importing a module from local directory

2006-05-13 Thread vduber6er
newbie reply, but how do i go about doing that? thanks! -- http://mail.python.org/mailman/listinfo/python-list

Question regarding checksuming of a file

2006-05-13 Thread Andrew Robert
Good evening, I need to generate checksums of a file, store the value in a variable, and pass it along for later comparison. The MD5 module would seem to do the trick but I'm sketchy on implementation. The nearest I can see would be import md5 m=md5.new() contents =

Re: Question regarding checksuming of a file

2006-05-13 Thread Edward Elliott
Andrew Robert wrote: m=md5.new() contents = open(self.file_name,rb).read() check=md5.update(contents) However this does not appear to be actually returning the checksum. the docs are your friend, use them. hint: first you eat, then you... http://docs.python.org/lib/module-md5.html --

Re: Question regarding checksuming of a file

2006-05-13 Thread Andrew Robert
Actually, I think I got it but would like to confirm this looks right. import md5 checksum = md5.new() mfn = open(self.file_name, 'r') for line in mfn.readlines(): checksum.update(line) mfn.close() cs = checksum.hexdigest() print

Re: Question regarding checksuming of a file

2006-05-13 Thread Roy Smith
In article [EMAIL PROTECTED], Andrew Robert [EMAIL PROTECTED] wrote: Good evening, I need to generate checksums of a file, store the value in a variable, and pass it along for later comparison. The MD5 module would seem to do the trick but I'm sketchy on implementation. The nearest

Re: Question regarding checksuming of a file

2006-05-13 Thread Andrew Robert
Roy Smith wrote: However this does not appear to be actually returning the checksum. Does anyone have insight into where I am going wrong? After calling update(), you need to call digest(). Update() only updates the internal state of the md5 state machine; digest() returns the hash.

Aggregate funuctions broken in MySQLdb?

2006-05-13 Thread Lorenzo
I'm trying to use some of the agg functions in MySQLdb (avg, min, max), but they're just not working as I would expect. They all return the value 1 when executed as part of Python scripts, but work as expected when used in mysql 4.1. Does anyone have any experience using Python with MySQLdb?

Re: How to install pyTrix?

2006-05-13 Thread DeepBlue
Hi, PyTrix can be obtained from http://www.american.edu/econ/pytrix/pytrix.htm cheers! Claudio Grondi wrote: DeepBlue wrote: Hi all, can any1 please tell me how to install pyTrix? thx! The first step should be to get it, but how can it be got? Claudio --

Re: distributing a app frozen by cx_freeze

2006-05-13 Thread Serge Orlov
Flavio wrote: Well I managed to get rid of the undefined symbol message by copying all qt libs to the freeze directory, the problem is that now the package is huge (83MB)! So my question is: is there a way to find out exactly which lib is missing ? I haven't done that myself, but I've had

Re: cx_freeze and matplotlib

2006-05-13 Thread Serge Orlov
Flavio wrote: I am trying to freeze an application which imports matplotlib. It all works fine on the machine where it was frozen. The executable runs without a glitch. But when I move the directory containing the frozen executable and other libs to a new machine, I get the following error:

Re: where do you run database scripts/where are DBs 'located'?

2006-05-13 Thread John Salerno
Dennis Lee Bieber wrote: On Sat, 13 May 2006 14:49:06 -0400, John Salerno [EMAIL PROTECTED] declaimed the following in comp.lang.python: Yeah, that's actually what I'm trying to do now. I'm not sure how to define it, but I assume it has something to do with 3306, since that's the default.

any plans to make pprint() a builtin?

2006-05-13 Thread John Salerno
Just wondering if this will ever happen, maybe in 3.0 when print becomes a function too? It would be a nice option to have it available without importing it every time, but maybe making it a builtin violates some kind of pythonic ideal? -- http://mail.python.org/mailman/listinfo/python-list

copying files into one

2006-05-13 Thread Gary Wessle
Hi I am looping through a directory and appending all the files in one huge file, the codes below should give the same end results but are not, I don't understand why the first code is not doing it. thanks combined = open(outputFile, 'wb') for name in flist: if os.path.isdir(file):

Re: retain values between fun calls

2006-05-13 Thread George Sakkis
Gary Wessle wrote: Hi the second argument in the functions below suppose to retain its value between function calls, the first does, the second does not and I would like to know why it doesn't? and how to make it so it does? thanks # it does def f(a, L=[]): L.append(a) return L

count items in generator

2006-05-13 Thread BartlebyScrivener
Still new. I am trying to make a simple word count script. I found this in the great Python Cookbook, which allows me to process every word in a file. But how do I use it to count the items generated? def words_of_file(thefilepath, line_to_words=str.split): the_file = open(thefilepath)

Re: copying files into one

2006-05-13 Thread Edward Elliott
Gary Wessle wrote: I am looping through a directory and appending all the files in one huge file, the codes below should give the same end results but are not, I don't understand why the first code is not doing it. combined = open(outputFile, 'wb') for name in flist: if

Re: copying files into one

2006-05-13 Thread Edward Elliott
Gary Wessle wrote: I am looping through a directory and appending all the files in one huge file, the codes below should give the same end results but are not, I don't understand why the first code is not doing it. another bit of friendly advice (for others as well): learn to use pdb before

do/while structure needed

2006-05-13 Thread John Salerno
1 random.shuffle(letters) 2 trans_letters = ''.join(letters)[:len(original_set)] 3 trans_table = string.maketrans(original_set, trans_letters) So what I'd like to do is have lines 1 and 2 run once, then I want to do some comparison between original_set and trans_letters before running line 3.

Re: count items in generator

2006-05-13 Thread Alex Martelli
BartlebyScrivener [EMAIL PROTECTED] wrote: Still new. I am trying to make a simple word count script. I found this in the great Python Cookbook, which allows me to process every word in a file. But how do I use it to count the items generated? def words_of_file(thefilepath,

Re: count items in generator

2006-05-13 Thread George Sakkis
BartlebyScrivener wrote: Still new. I am trying to make a simple word count script. I found this in the great Python Cookbook, which allows me to process every word in a file. But how do I use it to count the items generated? def words_of_file(thefilepath, line_to_words=str.split):

Re: count items in generator

2006-05-13 Thread BartlebyScrivener
Thanks! And thanks for the Cookbook. rd There is no abstract art. You must always start with something. Afterward you can remove all traces of reality.--Pablo Picasso -- http://mail.python.org/mailman/listinfo/python-list

Re: do/while structure needed

2006-05-13 Thread George Sakkis
John Salerno wrote: 1 random.shuffle(letters) 2 trans_letters = ''.join(letters)[:len(original_set)] 3 trans_table = string.maketrans(original_set, trans_letters) So what I'd like to do is have lines 1 and 2 run once, then I want to do some comparison between original_set and trans_letters

Re: count items in generator

2006-05-13 Thread Paul Rubin
George Sakkis [EMAIL PROTECTED] writes: As clunky as it seems, I don't think you can beat it in terms of brevity; if you care about memory efficiency though, here's what I use: def length(iterable): try: return len(iterable) except: i = 0 for x in iterable: i += 1

[ python-Feature Requests-1487389 ] datetime.time and datetime.timedelta

2006-05-13 Thread SourceForge.net
Feature Requests item #1487389, was opened at 2006-05-12 13:13 Message generated for change (Comment added) made by fresh You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=355470aid=1487389group_id=5470 Please note that this message will contain a full copy of the

[ python-Bugs-1487966 ] SystemError with conditional expression in assignment

2006-05-13 Thread SourceForge.net
Bugs item #1487966, was opened at 2006-05-13 18:25 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=105470aid=1487966group_id=5470 Please note that this message will contain a full copy of

[ python-Bugs-944394 ] No examples or usage docs for urllib2

2006-05-13 Thread SourceForge.net
Bugs item #944394, was opened at 2004-04-29 13:02 Message generated for change (Comment added) made by loewis You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=105470aid=944394group_id=5470 Please note that this message will contain a full copy of the comment thread,

[ python-Bugs-1487481 ] Could BIND_FIRST be removed on HP-UX?

2006-05-13 Thread SourceForge.net
Bugs item #1487481, was opened at 2006-05-12 17:32 Message generated for change (Comment added) made by loewis You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=105470aid=1487481group_id=5470 Please note that this message will contain a full copy of the comment

[ python-Bugs-944394 ] No examples or usage docs for urllib2

2006-05-13 Thread SourceForge.net
Bugs item #944394, was opened at 2004-04-29 12:02 Message generated for change (Comment added) made by jjlee You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=105470aid=944394group_id=5470 Please note that this message will contain a full copy of the comment thread,

[ python-Bugs-1487966 ] SystemError with conditional expression in assignment

2006-05-13 Thread SourceForge.net
Bugs item #1487966, was opened at 2006-05-13 18:25 Message generated for change (Comment added) made by zseil You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=105470aid=1487966group_id=5470 Please note that this message will contain a full copy of the comment thread,

  1   2   >