Re: Using a time duration to print out data where every 2 seconds is a pixel

2007-09-11 Thread Tim Roberts
[EMAIL PROTECTED] wrote: >Thanks however I am still having a problem using the time module for >arithmetic > >My string times are of values such as 09:55:17 > >and I have code such as: > >>from time import * >>startPoint = strptime(step.sTime, "%H:%S:%M") >>finishPoint = strptime(step.fTime, "%H:%

Re: newbie: stani's python editor if-else

2007-09-11 Thread Bruno Desthuilliers
madzientist a écrit : > hi, > two quick questions: > > a) i am using SPE (latest version) and for some reason, when i type, > say > > if 1==2: > print "not equal" > else: > print "equal" > > the else is at the same indentation level as the preceding print > statement, and i ge

Re: Using a time duration to print out data where every 2 seconds is a pixel

2007-09-11 Thread cjt22
On Sep 11, 8:58 am, Tim Roberts <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > >Thanks however I am still having a problem using the time module for > >arithmetic > > >My string times are of values such as 09:55:17 > > >and I have code such as: > > >>from time import * > >>startPoint = str

Re: Checking if elements are empty

2007-09-11 Thread Piet van Oostrum
> "Chris Mellon" <[EMAIL PROTECTED]> (CM) wrote: >CM> On 9/10/07, Neil Cerutti <[EMAIL PROTECTED]> wrote: >>> Agreed; but I prefer 'if y[0] == ""', absent more context and >>> better names. >CM> Probably should use u"" if you're going to take that route, as this >CM> will fail spuriously if

Re: Why is this loop heavy code so slow in Python? Possible Project Euler spoilers

2007-09-11 Thread Robert Brown
Neil Cerutti <[EMAIL PROTECTED]> writes: > On 2007-09-02, Steven D'Aprano > <[EMAIL PROTECTED]> wrote: >> A big question mark in my mind is Lisp, which according to >> aficionados is just as dynamic as Python, but has native >> compilers that generate code running as fast as highly >> optimized C.

Re: Python Database Apps

2007-09-11 Thread Uwe Grauer
[EMAIL PROTECTED] wrote: > Kindof a poll, kindof curiosity... > > What is your favorite python - database combination? I'm looking to > make an app that has a local DB and a server side DB. I'm looking at > python and sqlite local side and sql server side. > > Any suggestions > > Darien >

Re: Checking if elements are empty

2007-09-11 Thread Wildemar Wildenburger
Steve Holden wrote: > Neil Cerutti wrote: > >>> y = "" > >>> if y[0] == "": > ... print "True" > ... else: > ... print "False" > ... > Traceback (most recent call last): > File "", line 1, in > IndexError: string index out of range > >>> > Uhm, weren't we talking about a list of strings?

Re: why should I learn python

2007-09-11 Thread HowiPepper
On Sep 6, 5:32 pm, windandwaves <[EMAIL PROTECTED]> wrote: > Can someone tell me why I should learn python? I am a webdeveloper, > but I often see Python mentioned and I am curious to find out what I > am missing out on. > > Thank you > > Nicolaas Nicholaas, There are many reasons to learn Pytho

Re: why should I learn python

2007-09-11 Thread HowiPepper
Sorry Nicolaas, I didn't mean to misspell your name! Regards, Howard -- http://mail.python.org/mailman/listinfo/python-list

Re: Modul (%) in python not like in C?

2007-09-11 Thread J. Cliff Dyer
Bryan Olson wrote: > Scott David Daniels wrote: > >> C, which was designed as a "high level assembly language," does not >> tightly define the results of / and % for negative numbers. Instead >> it defines the result for positive over positive, and constrains the >> result for the others. >>

Re: printing list containing unicode string

2007-09-11 Thread Xah Lee
J. Cliff Dyer wrote: " ...UCS-2, for example, is a fixed width, 2-byte encoding that can handle any unicode code point up to 0x, but cannot handle the 3 and 4 byte extension sets. " I was going to reply to say that this is a good point. But on my way i looked up wikipedia, http://en.wikipedia

Re: Enum class with ToString functionality

2007-09-11 Thread J. Cliff Dyer
Zara wrote: > On Mon, 10 Sep 2007 02:28:57 -0700, [EMAIL PROTECTED] wrote: > > >> Hi, >> >> I have the following class - >> >> class TestOutcomes: >>PASSED = 0 >>FAILED = 1 >>ABORTED = 2 >> >> plus the following code - >> >> testResult = TestOutcomes.PASSED >> >> testResultAsString >

Re: Setting stdout encoding

2007-09-11 Thread Fabio Zadrozny
> > You could place code like that on sitecustomize.py > I think this should be fixed on Eclipse/pydev. If they replace sys.stdout > with a different object - they should make sure it has the right behavior. > Same for IDLE if it's broken too. > Thanks for the tip... I wasn't aware of sitecustomiz

Re: zlib

2007-09-11 Thread Milos Prudek
> > Although I have Python 2.5 with zlib in my Linux disto, I need to install > > my own Python (as most Zope developers do). > > Why? Because Zope often requires Python version slightly older than the most current one. > So why does your own Python version have to be 2.4.4? Because "Plone 3.0

cpython list __str__ method for floats

2007-09-11 Thread [david]
returns poorly formatted values: >>>str(13.3) '13.3' >>>str([13.3]) '[13.301]' [david] -- http://mail.python.org/mailman/listinfo/python-list

Re: Checking if elements are empty

2007-09-11 Thread Neil Cerutti
On 2007-09-10, Steve Holden <[EMAIL PROTECTED]> wrote: >> I have a quibble not with the functionality of the boolean check, >> but with its expressiveness. if y[0] == "" expresses more, i.e., >> that I expect y[0] to contain a Python byte string. > > I have a quibble with a test that will raise an

Re: function to do dynamic import?

2007-09-11 Thread J. Cliff Dyer
bambam wrote: > import works in the main section of the module, but does > not work as I hoped when run inside a function. > > That is, the modules import correctly, but are not visible to > the enclosing (global) scope. > > Questions: > (1) Where can I read an explanation of this? > (2) Is there a

Re: cpython list __str__ method for floats

2007-09-11 Thread TheFlyingDutchman
On Sep 11, 4:07 am, "[david]" <[EMAIL PROTECTED]> wrote: > returns poorly formatted values: > > >>>str(13.3) > '13.3' > >>>str([13.3]) > '[13.301]' > > [david] There is some difference in the way repr() and str() convert floats to strings: >>> a = 13.3 >>> print str(a) 13.3 >>> prin

Re: [PyCON-Organizers] Next PyCon Organizers' Meeting Tuesday, 11 September

2007-09-11 Thread VanL
Laura Creighton wrote: > Does this mean that if you do not have a google account, and do not > want one, there is no way to join the meeting? No. Any jabber/xmpp account will do fine. Google is just the highest-profile provider of jabber accounts. There is a list of other account providers on

Re: /dev/null as a file-like object, or logging to nothing

2007-09-11 Thread [david]
Lawrence D'Oliveiro wrote: > In message <[EMAIL PROTECTED]>, Sion Arrowsmith wrote: > >> Torsten Bronger <[EMAIL PROTECTED]> wrote: >>> Marc 'BlackJack' Rintsch writes: `os.devnull`? >>> Yes, but I wasn't really sure how portable it is, in particular, on >>> Windows. >> Windows has a NUL: de

Re: Python Database Apps

2007-09-11 Thread David
> What is your favorite python - database combination? I'm looking to > make an app that has a local DB and a server side DB. I'm looking at > python and sqlite local side and sql server side. > > Any suggestions I like to use elixir [1] on top of sqlalchemy [2] [1] http://elixir.ematia.de/

RE: Checking if elements are empty

2007-09-11 Thread Hamilton, William
> From: Steve Holden > Neil Cerutti wrote: > > On 2007-09-10, Chris Mellon <[EMAIL PROTECTED]> wrote: > >> On 9/10/07, Neil Cerutti <[EMAIL PROTECTED]> wrote: > >>> Agreed; but I prefer 'if y[0] == ""', absent more context and > >>> better names. > >> Probably should use u"" if you're going to take

Re: cpython list __str__ method for floats

2007-09-11 Thread Bjoern Schliessmann
[david] wrote: > returns poorly formatted values: Please explain. > >>>str(13.3) > '13.3' > >>>str([13.3]) > '[13.301]' This is quite a FAQ. str of a float returns the float, rounded to decimal precision. str of a list returns a square brackets enclosed enumeration of the content

Car-ac-systems

2007-09-11 Thread knjaz
Here you can find everything you need to know about car air conditioning http://car-ac-systems.blogspot.com/ -- http://mail.python.org/mailman/listinfo/python-list

Re: urllib2: handle an error (302)

2007-09-11 Thread Antoni Villalonga
2007/9/11, Lawrence D'Oliveiro: > In message <[EMAIL PROTECTED]>, Antoni > Villalonga wrote: > > > There are any way to handle a 302 error? > > I assume the answer you seek is here > . > -- > http://mail.python.org/mailman/listinfo/python-list

Re: anybody has py modules emulating symbian 60 on PC?

2007-09-11 Thread Steve Holden
Ginger wrote: > like appuifw/graphics/sysinfo modules, > i've get some primary modules of these, they do what they did on S60 > platform. u can get them from http://pdis.hiit.fi/pdis/ > but these modules i get are rather simple ones, and a full emulation is > needed ..., so anyone who has it, plz

IOError - list of all Errno numbers and their meanings?

2007-09-11 Thread Tim Couper
As you know, when an IOError is raised, you get a helpful: [Errno N] Is there a list of all possible values of N which can be returned, and their meanings? -- Dr Tim Couper CTO, SciVisum Ltd www.scivisum.com -- http://mail.python.org/mailman/listinfo/python-list

Re: memcpy

2007-09-11 Thread Tim
On Sep 10, 3:31 pm, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote: > On Mon, 10 Sep 2007 11:38:50 -0700, Tim wrote: > > How do I memcpy from a pointer to an array of floats in python? > > > I get errors: NameError: global name 'row' is not defined > > Well than the (global) name `row` is not d

Re: Mac OSX sqlite problem. Missing?

2007-09-11 Thread scottishguy
On Sep 11, 2:46 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > On Sep 10, 1:51 pm, [EMAIL PROTECTED] wrote: > > > > > Diez B. Roggisch wrote: > > > > Are you by any chance using the python 2.3 when issuing that import > > > statement? > > > > Diez > > > Unfortunately not :( > > > ibook:~/proj

Re: function to do dynamic import?

2007-09-11 Thread Steve Holden
bambam wrote: > import works in the main section of the module, but does > not work as I hoped when run inside a function. > > That is, the modules import correctly, but are not visible to > the enclosing (global) scope. > > Questions: > (1) Where can I read an explanation of this? > (2) Is there

Re: XML: SAX and XInclude

2007-09-11 Thread Laurent Pointal
Stefan Behnel a écrit : > Laurent Pointal wrote: >> does anybody know about an XML parser usable with the sax API (xml.sax) >> and with XInclude feature support (directly or via hacks). > > Try lxml.etree. > > http://codespeak.net/lxml/ > > http://codespeak.net/lxml/tutorial.html > http://codesp

Re: IOError - list of all Errno numbers and their meanings?

2007-09-11 Thread Jeff McNeil
The 'errno' number (at least on the *nix platforms I use) corresponds to the 'errno' number set on system call failure. POSIX.1 specifies a set of standard errors. AFAIK, the 'errno' module should contain the mappings for your system. On 9/11/07, Tim Couper <[EMAIL PROTECTED]> wrote: > As you k

Re: Mac OSX sqlite problem. Missing?

2007-09-11 Thread Steve Holden
scottishguy wrote: > On Sep 11, 2:46 am, "[EMAIL PROTECTED]" > <[EMAIL PROTECTED]> wrote: >> On Sep 10, 1:51 pm, [EMAIL PROTECTED] wrote: >> >> >> >>> Diez B. Roggisch wrote: Are you by any chance using the python 2.3 when issuing that import statement? Diez >>> Unfortunately not :(

Re: IOError - list of all Errno numbers and their meanings?

2007-09-11 Thread Marc 'BlackJack' Rintsch
On Tue, 11 Sep 2007 13:08:25 +0100, Tim Couper wrote: > As you know, when an IOError is raised, you get a helpful: > > [Errno N] > > Is there a list of all possible values of N which can be returned, and > their meanings? Take a look at the `errno` module and the `os.strerror()` function. Ci

Re: newbie: stani's python editor if-else

2007-09-11 Thread Steve Holden
madzientist wrote: > hi, > > two quick questions: > > a) i am using SPE (latest version) and for some reason, when i type, > say > > if 1==2: > print "not equal" > else: > print "equal" > > the else is at the same indentation level as the preceding print > statement, and i get

Re: memcpy

2007-09-11 Thread Laurent Pointal
Tim a écrit : > Can I initialize something in Python that I can get access to it's > pointer? No, there is no pointer in Python semantic (they exist behind the scene in C-Python). > How about: > > self.data = > TOTAL_OUTPUT_PARMETERS*[TOTAL_PARAMETER_ENTRIES*[c_float()] > > or > > self.data

Re: Checking if elements are empty

2007-09-11 Thread Steve Holden
Hamilton, William wrote: >> From: Steve Holden >> Neil Cerutti wrote: >>> On 2007-09-10, Chris Mellon <[EMAIL PROTECTED]> wrote: On 9/10/07, Neil Cerutti <[EMAIL PROTECTED]> wrote: > Agreed; but I prefer 'if y[0] == ""', absent more context and > better names. Probably should use

Re: Checking if elements are empty

2007-09-11 Thread Steve Holden
Neil Cerutti wrote: > On 2007-09-10, Steve Holden <[EMAIL PROTECTED]> wrote: >>> I have a quibble not with the functionality of the boolean check, >>> but with its expressiveness. if y[0] == "" expresses more, i.e., >>> that I expect y[0] to contain a Python byte string. >> I have a quibble with a

Re: shared memory pointer

2007-09-11 Thread Tim Golden
Tim wrote: > I saw the mmap function in the shared memory example. I had some > concern with my large memory size being written to the disk drive. I > though it might slow down my application. The reason I am writting > this new code is because the existing method using a file. I thought > shared m

Re: Enum class with ToString functionality

2007-09-11 Thread Scott David Daniels
[EMAIL PROTECTED] wrote: > Hi, > > I have the following class - > > class TestOutcomes: > PASSED = 0 > FAILED = 1 > ABORTED = 2 > > plus the following code - > > testResult = TestOutcomes.PASSED > > testResultAsString > if testResult == TestOutcomes.PASSED: > testResultAsStrin

Re: memcpy

2007-09-11 Thread Marc 'BlackJack' Rintsch
On Tue, 11 Sep 2007 05:09:58 -0700, Tim wrote: > On Sep 10, 3:31 pm, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote: >> On Mon, 10 Sep 2007 11:38:50 -0700, Tim wrote: >> > How do I memcpy from a pointer to an array of floats in python? >> >> > I get errors: NameError: global name 'row' is not

Go Here to win a free guitar

2007-09-11 Thread nutsbreaker1
http://freeguitars.blogspot.com/ -- http://mail.python.org/mailman/listinfo/python-list

Re: memcpy

2007-09-11 Thread Tim
On Sep 11, 8:01 am, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote: > On Tue, 11 Sep 2007 05:09:58 -0700, Tim wrote: > > On Sep 10, 3:31 pm, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote: > >> On Mon, 10 Sep 2007 11:38:50 -0700, Tim wrote: > >> > How do I memcpy from a pointer to an array

Re: newbie: stani's python editor if-else

2007-09-11 Thread kyosohma
On Sep 10, 11:24 pm, madzientist <[EMAIL PROTECTED]> wrote: > hi, > > two quick questions: > > a) i am using SPE (latest version) and for some reason, when i type, > say > > if 1==2: > print "not equal" > else: > print "equal" > > the else is at the same indentation level as the p

RE: newbie: stani's python editor if-else

2007-09-11 Thread Hamilton, William
> -Original Message- > From: [EMAIL PROTECTED] [mailto:python- > [EMAIL PROTECTED] On Behalf Of > [EMAIL PROTECTED] > Sent: Tuesday, September 11, 2007 8:26 AM > To: python-list@python.org > Subject: Re: newbie: stani's python editor if-else > > On Sep 10, 11:24 pm, madzientist <[EMAIL PRO

Re: Car-ac-systems

2007-09-11 Thread John Timney \(MVP\)
How do I control one with C# then! Thats not on your site, clearly not everything I need to know then. Waste of a site! Regards John Timney (MVP) http://www.johntimney.com http://www.johntimney.com/blog "knjaz" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Here you can find

Re: urllib2: handle an error (302)

2007-09-11 Thread O.R.Senthil Kumaran
> When urllib2 libs visit a URL with 302 error follow the location > automatically. I need to get the location in order to get the full > URL (not relative URL) parsing html code. urllib2 automatically handles the 302 redirection. What you get as the end result is the 'redirected' page. - If al

Minor documentation bug

2007-09-11 Thread Frank Millman
Hi all I spotted a minor bug in the documentation to SimpleXMLRPCServer. It does not seem worth getting a login to the bugtracker just to enter this, so if it is confirmed as a bug perhaps someone would be so kind as to enter it for me. Background: xmlrpclib.py has the following - # Thi

Re: Why is this loop heavy code so slow in Python? Possible Project Euler spoilers

2007-09-11 Thread Neil Cerutti
On 2007-09-11, Robert Brown <[EMAIL PROTECTED]> wrote: > Neil Cerutti <[EMAIL PROTECTED]> writes: > >> On 2007-09-02, Steven D'Aprano >> <[EMAIL PROTECTED]> wrote: >>> A big question mark in my mind is Lisp, which according to >>> aficionados is just as dynamic as Python, but has native >>> compile

Re: Car-ac-systems

2007-09-11 Thread Lew
John Timney (MVP) wrote: > How do I control one with C# then! Thats not on your site, clearly not > everything I need to know then. Waste of a site! Please do not top post. > "knjaz" <[EMAIL PROTECTED]> wrote in message >> Here you can find everything you need to know about car air >> conditi

Re: pipes

2007-09-11 Thread Daniel Klein
On Mon, 10 Sep 2007 20:15:40 -0700, yagyala <[EMAIL PROTECTED]> wrote: >Hi. I'm rtying to use pipes to communicate between a python GUI and a >spawned C++ program. I prefer not to use forking because the app may >be run on windows, where forking isn't supported. Roughly what I'm >doing is: > >(r,w

Re: shared memory pointer

2007-09-11 Thread Tim
WowYou put some detail in this response. Thanks so much! I think I want to stay away from mmap because it uses the disk to store my memory. I am trying to stay away from that. I am building strip charts in this python project to view my data. Currently, I am using a file and I have to open the

Re: newbie: stani's python editor if-else

2007-09-11 Thread Gregor Horvath
[EMAIL PROTECTED] schrieb: > I agree with Steve. I have yet to see an IDE for Python (or anything > else) that unindents statements. Even IDLE, the Official IDE for > Python, doesn't do that. emacs in python-mode Just hit TAB and it unindents "else" in the given example. Hit TAB again and it cy

Re: Python Database Apps

2007-09-11 Thread Ed Leafe
On Sep 10, 2007, at 10:52 PM, [EMAIL PROTECTED] wrote: > Kindof a poll, kindof curiosity... > > What is your favorite python - database combination? I'm looking to > make an app that has a local DB and a server side DB. I'm looking at > python and sqlite local side and sql server side.

Re: Car-ac-systems

2007-09-11 Thread John Timney \(MVP\)
Thats all it is. It may have been a usefully intended resource once, but they have no controls whatsoever. Its time someone closed it down. Regards John Timney (MVP) http://www.johntimney.com http://www.johntimney.com/blog "Lew" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >

Make money to share photos

2007-09-11 Thread anky
Make money to share photos Do you want to make money to post photos from internet.then just move on to http://goodtolove.com and start posting.They will pay their 50% adsense revenue with you...Then what are you waiting for just start posting photos in http://goodtolove.com. -- http://mail.python

Re: newbie: stani's python editor if-else

2007-09-11 Thread Steve Holden
Hamilton, William wrote: >> -Original Message- >> From: [EMAIL PROTECTED] > [mailto:python- >> [EMAIL PROTECTED] On Behalf Of >> [EMAIL PROTECTED] >> Sent: Tuesday, September 11, 2007 8:26 AM >> To: python-list@python.org >> Subject: Re: newbie: stani's python editor if-else >> >> On Sep 10

Re: newbie: stani's python editor if-else

2007-09-11 Thread Bruno Desthuilliers
Steve Holden a écrit : > madzientist wrote: >> hi, >> >> two quick questions: >> >> a) i am using SPE (latest version) and for some reason, when i type, >> say >> >> if 1==2: >> print "not equal" >> else: >> print "equal" >> >> the else is at the same indentation level as the prec

Python 2 releases after 2.6

2007-09-11 Thread slinkp
This seems to be a bit of a FAQ (at least among worried Zope developers :-) ... What are the plans for Python 2 releases after Python 2.6 / Python 3 are released? First, in the 2006 State of Python, Guido said: """ # 2.7: likely; may contain some 3.0 backports # 2.9 is as far as we'll go (runni

Re: shared memory pointer

2007-09-11 Thread Tim Golden
Tim wrote: > I think I want to stay away from mmap because it uses the disk to > store my memory. My point is that, whatever mmap is doing, your own code is doing *exactly the same thing*. Passing the INVALID_HANDLE_VALUE as both your code and the mmap code are doing is documented as producing an

Re: Car-ac-systems

2007-09-11 Thread Steve Holden
John Timney (MVP) wrote: > Thats all it is. It may have been a usefully intended resource once, but > they have no controls whatsoever. Its time someone closed it down. > What is it about "please do not top-post" that you have difficulty understanding? Or do "MVP"s feel that their time is so m

Re: Minor documentation bug

2007-09-11 Thread Tim Golden
Frank Millman wrote: > I spotted a minor bug in the documentation to SimpleXMLRPCServer. It > does not seem worth getting a login to the bugtracker just to enter > this, so if it is confirmed as a bug perhaps someone would be so kind > as to enter it for me. Frank, please do take the trouble to en

Re: Car-ac-systems

2007-09-11 Thread Diez B. Roggisch
Steve Holden wrote: > John Timney (MVP) wrote: >> Thats all it is. It may have been a usefully intended resource once, but >> they have no controls whatsoever. Its time someone closed it down. >> > What is it about "please do not top-post" that you have difficulty > understanding? Or do "MVP"s

Py2.5.1 on Ubuntu AMD X2, unicode problems

2007-09-11 Thread Harry George
I'm building 2.5.1 from source, using the ubuntu(7.0.4)-provided gcc 4.1.2. Based on google searches and nints found, here is the process: #---edit configure; test of wchar_t--- #include #include #-

ValueError: insecure string pickle ?

2007-09-11 Thread robert
cPickle.loads raised "ValueError: insecure string pickle". The error is from a log file and I cannot reproduce it (quickly). What can be the cause for that error? Robert -- http://mail.python.org/mailman/listinfo/python-list

Re: memcpy

2007-09-11 Thread Marc 'BlackJack' Rintsch
On Tue, 11 Sep 2007 06:22:19 -0700, Tim wrote: > Is this what you mean? Python did not like the word c_types in front > of POINTER. Do you know why? Yes I know. Read up how importing works. > How can I re-declare a function's return type if it is declared > somewhere else? The return type of C

Excel process still running after program completion.

2007-09-11 Thread Chris
I have a python script that is driving Excel and using the win32com module. However, upon program completion there's still an Excel.exe process running in the background that I must terminate through Task Manager. Reading up on other threads indicate that maybe I still have some Excel objects refer

mod_python and pysvn

2007-09-11 Thread Sjoerd
Hello all, I have a script that uses pySVN. It gets the latest build information. I want to create a call to that function in a PSP file but everytime I try I get an error message: ClientError: Unable to open an ra_local session to URL Unable to open repository 'file:///P:/tools/builds/repository

Re: mod_python and pysvn

2007-09-11 Thread Tim Golden
Sjoerd wrote: > Hello all, > > I have a script that uses pySVN. It gets the latest build information. > I want to create a call to that function in a PSP file but everytime I > try I get an error message: > > ClientError: Unable to open an ra_local session to URL > Unable to open repository 'file

Re: Why zlib not included in Python tarball?

2007-09-11 Thread Milos Prudek
> Depends on the operating system and the Python version. On Unix, you > need to install zlib first; if you install a precompiled zlib package, > make sure you install the header files as well. You were right. Thank you. -- Milos Prudek -- http://mail.python.org/mailman/listinfo/python-list

Re: customizing a logging logger

2007-09-11 Thread garyjefferson123
I think the following question is clearer. I want to make it so that method1 below can be transformed: logger = logging.getLogger("somelogger") class SomeOp: def __init__(self, ctx): self.ctx = ctx def method1(self): logger.info("%s: here's a message", self.ctx) lo

Re: printing list containing unicode string

2007-09-11 Thread Sion Arrowsmith
Xah Lee <[EMAIL PROTECTED]> wrote: > " It's very wasteful of space. In most texts, the majority of the >code points are less than 127, or less than 255, so a lot of space is >occupied by zero bytes. " > >Not true. In Asia, most chars has unicode number above 255. Considered >globally, *possibly*

RE: Excel process still running after program completion.

2007-09-11 Thread Hamilton, William
> From: Chris > > I have a python script that is driving Excel and using the win32com > module. However, upon program completion there's still an Excel.exe > process running in the background that I must terminate through Task > Manager. Reading up on other threads indicate that maybe I still have

Re: Car-ac-systems

2007-09-11 Thread Hunter Gratzner
[top posting fixed] > "Lew" <[EMAIL PROTECTED]> wrote in message > > news:[EMAIL PROTECTED] > > I'm starting to see "blogspot" as a synonym for "spam". On Sep 11, 4:33 pm, "John Timney \(MVP\)" <[EMAIL PROTECTED]> wrote: > Thats all it is. It may have been a usefully intended resource once, but

Re: creating really big lists

2007-09-11 Thread Dr Mephesto
On Sep 8, 8:06 pm, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: > Dr Mephesto a écrit : > > > Hi! > > > I would like to create a pretty big list of lists; a list 3,000,000 > > long, each entry containing 5 empty lists. My application will append > > data each of the 5 sublists, so they will be of

Python code-writing for the blind. Was (Re: newbie: stani's python editor if-else)

2007-09-11 Thread madzientist
Thanks, everybody, for the very very useful and kind responses. There is a second reason why I asked the question about automatic de- indenting. I am teaching myself Python partly so I can then help my technically astute, but blind friend learn programming. For the many reasons that Pythonistas l

Re: ValueError: insecure string pickle ?

2007-09-11 Thread Peter Otten
Am Tue, 11 Sep 2007 17:19:36 +0200 schrieb robert: > cPickle.loads raised "ValueError: insecure string pickle". > The error is from a log file and I cannot reproduce it (quickly). > What can be the cause for that error? A corrupted pickle. The error is raised if a string in the dump does not bo

RE: Python code-writing for the blind. Was (Re: newbie: stani's pythoneditor if-else)

2007-09-11 Thread Hamilton, William
> From: madzientist > > Thanks, everybody, for the very very useful and kind responses. > > There is a second reason why I asked the question about automatic de- > indenting. I am teaching myself Python partly so I can then help my > technically astute, but blind friend learn programming. For the

Re: Python code-writing for the blind. Was (Re: newbie: stani's python editor if-else)

2007-09-11 Thread Gregor Horvath
madzientist schrieb: > > Is Python a bad choice for the blind programmer, as a result of a > tight linkage between visual aspects of the code and its function ? I > wish the site blindprogramming.com weren't so lifeless... There was a thread regarding blind people and python indentation shortly:

Re: Excel process still running after program completion.

2007-09-11 Thread Chris
On Sep 11, 12:59 pm, "Hamilton, William " <[EMAIL PROTECTED]> wrote: > > From: Chris > > > I have a python script that is driving Excel and using the win32com > > module. However, upon program completion there's still an Excel.exe > > process running in the background that I must terminate through

Re: Excel process still running after program completion.

2007-09-11 Thread Chris
On Sep 11, 1:26 pm, Chris <[EMAIL PROTECTED]> wrote: > On Sep 11, 12:59 pm, "Hamilton, William " <[EMAIL PROTECTED]> wrote: > > > > > > From: Chris > > > > I have a python script that is driving Excel and using the win32com > > > module. However, upon program completion there's still an Excel.exe >

Re: Car-ac-systems

2007-09-11 Thread Rory Becker
> Thats all it is. It may have been a usefully intended resource once, > but they have no controls whatsoever. Its time someone closed it > down. Some would say the same thing about email or the internet at large. It doesn't make it true. Pick almost any community facility and you will find e

Re: Modul (%) in python not like in C?

2007-09-11 Thread Matthew Woodcraft
J. Cliff Dyer <[EMAIL PROTECTED]> wrote: >Bryan Olson wrote: >> Not true. Here it is again: >> >> When integers are divided, the result of the / operator is >> the algebraic quotient with any fractional part discarded.(87) >> If the quotient a/b is representable, the expression >>

Re: unexpected behavior: did i create a pointer?

2007-09-11 Thread Peter Otten
Am Sat, 08 Sep 2007 09:44:24 + schrieb Steven D'Aprano: > Ways that Python objects are not like C pointers: > > (1) You don't have to manage memory yourself. > > (2) You don't have typecasts. You can't change the type of the object you > point to. > > (3) Python makes no promises about the

Re: Python code-writing for the blind. Was (Re: newbie: stani's python editor if-else)

2007-09-11 Thread madzientist
Thanks, Gregor. Very helpful thread. Suresh On Sep 11, 1:26 pm, Gregor Horvath <[EMAIL PROTECTED]> wrote: > madzientist schrieb: > > > > > Is Python a bad choice for the blind programmer, as a result of a > > tight linkage between visual aspects of the code and its function ? I > > wish the site

Re: mod_python and pysvn

2007-09-11 Thread Bjoern Schliessmann
Tim Golden wrote: > Sjoerd wrote: >> ClientError: Unable to open an ra_local session to URL >> Unable to open repository 'file:///P:/tools/builds/repository' >> >> does anyone know how I can fix this? > > Usually means that the process which Apache is running under > (may well be LocalSystem) do

Re: Car-ac-systems

2007-09-11 Thread Zentrader
What is it about "please do not top-post" that you have difficulty understanding? Or do "MVP"s feel that their time is so much more valuable than anyone else's that they are free to ignore the norms? Who made this the norm? In my travels through web-land, it appears to be the opposite. Don't wa

Re: Car-ac-systems

2007-09-11 Thread Marc 'BlackJack' Rintsch
On Tue, 11 Sep 2007 17:42:53 +, Zentrader wrote: > > What is it about "please do not top-post" that you have difficulty > understanding? Or do "MVP"s feel that their time is so much more > valuable than anyone else's that they are free to ignore the norms? > > Who made this the norm? Common

Re: Car-ac-systems

2007-09-11 Thread J. Clifford Dyer
On Tue, Sep 11, 2007 at 05:50:43PM +, Marc 'BlackJack' Rintsch wrote regarding Re: Car-ac-systems: > > On Tue, 11 Sep 2007 17:42:53 +, Zentrader wrote: > > > > > What is it about "please do not top-post" that you have difficulty > > understanding? Or do "MVP"s feel that their time is so

Help With PyParsing of output from win32pdhutil.ShowAllProcesses()

2007-09-11 Thread Steve
Hi All (especially Paul McGuire!) Could you lend a hand in the grammar and paring of the output from the function win32pdhutil.ShowAllProcesses()? This is the code that I have so far (it is very clumsy at the moment) : import string import win32api import win32pdhutil import re import pyparsing

Re: Python code-writing for the blind. Was (Re: newbie: stani's pythoneditor if-else)

2007-09-11 Thread Bruno Desthuilliers
Hamilton, William a écrit : >>From: madzientist >> >>Thanks, everybody, for the very very useful and kind responses. >> >>There is a second reason why I asked the question about automatic de- >>indenting. I am teaching myself Python partly so I can then help my >>technically astute, but blind frien

Re: customizing a logging logger

2007-09-11 Thread David
On 9/11/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > I think the following question is clearer. > > I want to make it so that method1 below can be transformed: > > logger = logging.getLogger("somelogger") > class SomeOp: > def __init__(self, ctx): > self.ctx = ctx > def method

Re: mod_python and pysvn

2007-09-11 Thread Sjoerd
On Sep 11, 7:41 pm, Bjoern Schliessmann wrote: > Tim Golden wrote: > > Sjoerd wrote: > >> ClientError: Unable to open an ra_local session to URL > >> Unable to open repository 'file:///P:/tools/builds/repository' > > >> does anyone know how I can fix this? > > > Usually means that the process whic

Re: Help With PyParsing of output from win32pdhutil.ShowAllProcesses()

2007-09-11 Thread David
On 9/11/07, Steve <[EMAIL PROTECTED]> wrote: > Hi All (especially Paul McGuire!) > > Could you lend a hand in the grammar and paring of the output from the > function win32pdhutil.ShowAllProcesses()? > > This is the code that I have so far (it is very clumsy at the > moment) : Any particular reaso

Re: Car-ac-systems

2007-09-11 Thread Steve Holden
Zentrader wrote: > > What is it about "please do not top-post" that you have difficulty > understanding? Or do "MVP"s feel that their time is so much more > valuable than anyone else's that they are free to ignore the norms? > [Actually I wrote the bit above [to a third party], but apparently ze

Re: ValueError: insecure string pickle ?

2007-09-11 Thread Steve Holden
robert wrote: > cPickle.loads raised "ValueError: insecure string pickle". > The error is from a log file and I cannot reproduce it (quickly). > What can be the cause for that error? > > Robert Make sure that your pickle files are being read and written in binary mode ("rb" and "wb" as the sec

Re: Car-ac-systems

2007-09-11 Thread John Timney \(MVP\)
"Marc 'BlackJack' Rintsch" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On Tue, 11 Sep 2007 17:42:53 +, Zentrader wrote: > >> >> What is it about "please do not top-post" that you have difficulty >> understanding? Or do "MVP"s feel that their time is so much more >> valuable

Re: Python 2 releases after 2.6

2007-09-11 Thread Steve Holden
slinkp wrote: > This seems to be a bit of a FAQ (at least among worried Zope > developers :-) ... > What are the plans for Python 2 releases after Python 2.6 / Python 3 > are released? > > First, in the 2006 State of Python, Guido said: > > """ > # 2.7: likely; may contain some 3.0 backports >

Re: Python Database Apps

2007-09-11 Thread [EMAIL PROTECTED]
On Sep 11, 9:25 am, Ed Leafe <[EMAIL PROTECTED]> wrote: > On Sep 10, 2007, at 10:52 PM, [EMAIL PROTECTED] wrote: > > > Kindof a poll, kindof curiosity... > > > What is your favorite python - database combination? I'm looking to > > make an app that has a local DB and a server side DB. I'm looking

Lost in __setstate__() in C++ and swig

2007-09-11 Thread Martin Drautzburg
I am trying to cPickle/unpickle a C++ extension class with some private data members. I wrote __getstate__() and __setstate__ in C++ (I have to, due to the private data). Pickling writes the following file: ccopy_reg _reconstructor p1 (cpyramid MidiBytes

  1   2   >