ANN: python-ldap-2.0.10

2005-09-23 Thread Michael Ströder
Find a new release of python-ldap: http://python-ldap.sourceforge.net/ python-ldap provides an object-oriented API to access LDAP directory servers from Python programs. It mainly wraps the OpenLDAP 2.x libs for that purpose. Additionally it contains modules for other LDAP-related stuff (e.g.

ANN: Voidspace Updates - Jalopy, logintools, textmacros, downman (etc)

2005-09-23 Thread Fuzzyman
Hello All, There have been various updates to the Voidspace modules : Jalopy 0.6.0 http://www.voidspace.org.uk/python/cgi.shtml#jalopy A collaborative website designer (CGI). It uses Kupu (http://kupu.oscom.org ) the WYSIWYG HTML editor. This update moves to Kupu 1.3 and the pythonutils 0.2.2

How to use a timer in Python?

2005-09-23 Thread Nico Grubert
Hi there, on a Linux machine running Python 2.3.5. I want to create a file 'newfile' in a directory '/tmp' only if there is no file 'transfer.lock' in '/temp'. A cronjob creates a file 'transfer.lock' in '/temp' directory every 15 minutes while the cronjob is doing something. This job takes

Re: How to use a timer in Python?

2005-09-23 Thread Sybren Stuvel
Nico Grubert enlightened us with: How can I use a timer that waits e.g. 10 seconds if 'transfer.lock' is present and then checks again if 'transfer.lock' is still there? Make a while loop in which you sleep. Or use the threading module if you want to go multi-threading. Sybren -- The problem

Re: How to use a timer in Python?

2005-09-23 Thread Wolfram Kraus
Nico Grubert wrote: Hi there, on a Linux machine running Python 2.3.5. I want to create a file 'newfile' in a directory '/tmp' only if there is no file 'transfer.lock' in '/temp'. A cronjob creates a file 'transfer.lock' in '/temp' directory every 15 minutes while the cronjob is doing

Re: words relating to networks that I should probably know

2005-09-23 Thread Alessandro Bottoni
John Walton wrote: Hello, again. I'm back with my instant messenger project. My teacher has assigned us to write our papers, excluding the procedure, results, and conclusion. One of my topics is going to be networks. Does anyone know a list of words relating to networking/networks that

Re: Help on regular expression match

2005-09-23 Thread Fredrik Lundh
Johnny Lee wrote: I've met a problem in match a regular expression in python. Hope any of you could help me. Here are the details: I have many tags like this: xxxa href=http://xxx.xxx.xxx; xx xxxa href=wap://xxx.xxx.xxx xx xxxa href=http://xxx.xxx.xxx; xx

Re: Character Sequence Generation

2005-09-23 Thread Peter Otten
Jeff Schwab wrote: What's the best way to generate a sequence of characters in Python? I'm looking for something like this Perl code: 'a' .. 'z' . import re def char_set(a_z, all_chars=.join(map(chr, range(256: ... return re.compile([%s] % a_z).findall(all_chars) ... for c in

Re: C#3.0 and lambdas

2005-09-23 Thread Reinhold Birkenfeld
Erik Wilsher wrote: Python developement is discussed, decided and usually developed within the members of python-dev. Have you seen any discussions about xml-literals in python-dev lately? No. I don't need them, so I don't start a discussion. If you need them, or you want them, feel free to

Python argv and special characters

2005-09-23 Thread trapeze . jsg
Hi. Platform: Win XP Python version: 2.4.1 Running script from: cmd.exe (windows console) I am having some trouble passing arguments to a python script having special characters. In my case the argument is a filename (eg. udtræk.xml). It seems like python tries to guess the

Re: Python argv and special characters

2005-09-23 Thread Neil Hodgson
Jakob Simon-Gaarde: How can I ensure a safe passing of arguments maybe having speciel characters within. Use ctypes to call the Windows GetCommandLine function. The CommandLineToArgvW function can be used to break up the command line string into arguments. Neil --

Re: How to use a timer in Python?

2005-09-23 Thread Nico Grubert
Hi Sybren and Wolfram, thank you very much for the time.sleep() tip. My program reads like this now. import os import time WINDOWS_SHARE = 'C:\\Temp' while 'transfer.lock' in os.listdir( WINDOWS_SHARE ): print Busy, please wait... time.sleep(10) f = open(WINDOWS_SHARE + '/myfile',

Re: Ide RAD for linux?

2005-09-23 Thread Adriaan Renting
I use Eric3 as IDE on Linux. -- http://mail.python.org/mailman/listinfo/python-list

Re: How to use a timer in Python?

2005-09-23 Thread Paul Rubin
Nico Grubert [EMAIL PROTECTED] writes: while 'transfer.lock' in os.listdir( WINDOWS_SHARE ): print Busy, please wait... time.sleep(10) f = open(WINDOWS_SHARE + '/myfile', 'w') But there's a race condition, and don't you have to make your own lock before writing myfile, so that the

Re: subprocess.Popen and replacing the shell pipe line

2005-09-23 Thread [EMAIL PROTECTED]
by the way, you're re-inventing the wheel somewhat, check out the stdlib pipes module (http://docs.python.org/lib/module-pipes.html) -- http://mail.python.org/mailman/listinfo/python-list

Re: How to use a timer in Python?

2005-09-23 Thread Nick Craig-Wood
Nico Grubert [EMAIL PROTECTED] wrote: on a Linux machine running Python 2.3.5. I want to create a file 'newfile' in a directory '/tmp' only if there is no file 'transfer.lock' in '/temp'. A cronjob creates a file 'transfer.lock' in '/temp' directory every 15 minutes while the cronjob

pymssql and bind variables

2005-09-23 Thread Albert Leibbrandt
I need to write a little app that connects to an MS SQL server and for this I decided on the pymssql module. At this stage I am trying to find out if MS SQL server can handle bind variables. If anybody can give me an answer and perhaps a example it will be appreciated Thanks Albert

Re: Stampare su stampante aghi

2005-09-23 Thread Adriaan Renting
|lux [EMAIL PROTECTED] 09/22/05 4:01 pm |Salve a tutti, |sono alle prese con delle stampe su |stampanti ad aghi... | |Per stampare puro testo la soluzione più gettonata |sembra essere | |f = open(LPT1:) |f.write(bla bla) |f.close() | |devo dire che funziona benissimo, ma mi piacerebbe

Re: idle

2005-09-23 Thread TK
Hi Franz, is there no IDLE in Python2.4? Sure, on Windows: C:\Python24\Lib\idlelib\idle.pyw You should have a shortcuts in your StartMenu und Python 2.4 What about with Suse 9.3 und Python 2.4? o-o Thomas -- http://mail.python.org/mailman/listinfo/python-list

Re: re.split() problem

2005-09-23 Thread Takemura Masayuki
Thanks for your reply. In Re: re.split() problem [Fredrik] = Fredrik Lundh wrote Fredrik s = foo\nbar\n\nbaz Fredrik re.findall((?s).*\n\n|.+$, s) Fredrik ['foo\nbar\n\n', 'baz'] Fredrik (this also lets you use finditer so you can process huge texts without Fredrik having to

Re: Wrapping classes

2005-09-23 Thread bruno modulix
Jeremy Sanders wrote: Is it possible to implement some sort of lazy creation of objects only when the object is used, but behaving in the same way as the object? Smells like a Proxy pattern... For instance: class Foo: def __init__(self, val): This is really slow. self.num =

Re: idle

2005-09-23 Thread Peter Otten
TK wrote: is there no IDLE in Python2.4? What about with Suse 9.3 und Python 2.4? You have to install the python-idle package. Peter -- http://mail.python.org/mailman/listinfo/python-list

Re: Python argv and special characters

2005-09-23 Thread trapeze . jsg
thanks :-) It seems a little overkill though, is it really the only/best way? -- http://mail.python.org/mailman/listinfo/python-list

Re: How to use a timer in Python?

2005-09-23 Thread Nico Grubert
That all sounds very race-y to me! The cron-job and the other process need to take the same lock, otherwise the cron-job will start 1ms after the other process checks for transfer.lock and before it has a chance to create newfile and there will be trouble. Using files as locks isn't

Re: Alternatives to Stackless Python?

2005-09-23 Thread Christophe
[EMAIL PROTECTED] a écrit : I found LGT http://lgt.berlios.de/ but it didn't seem as if the NanoThreads module had the same capabilites as stackless. What specific capabilities of Stackless are you looking for, that are missing from NanoThreads? Capabilities of the different threadlike

Re: Wrapping classes

2005-09-23 Thread Paolino
Paolino wrote: class NotInitializedObjects(type): def __init__(cls,*_): realInit=cls.__init__ def __newInit__(self,*pos,**key): def _init(): realInit(self,*pos,**key) self._init=_init cls.__init__=__newInit__ def __getattribute__(self,attr):

Re: C#3.0 and lambdas

2005-09-23 Thread Fredrik Lundh
Reinhold Birkenfeld wrote: And I think the discussion that followed proved your point perfectly Fredrik. Big discussion over fairly minor things, but no big picture. Where are the initiatives on the big stuff (common documentation format, improved build system, improved web modules,

Re: strange import phenomenon

2005-09-23 Thread Christoph Zwerschke
One idea that seems to work is setting __name__ = '__main__' Or, del sys.modules[__name__]. -- http://mail.python.org/mailman/listinfo/python-list

Re: Python argv and special characters

2005-09-23 Thread Neil Hodgson
Jakob Simon-Gaarde: thanks :-) It seems a little overkill though, is it really the only/best way? Yes. I should have mentioned you want the wide version of the function GetCommandLineW. I wrote a patch to allow unicode in argv but later agreed that the patch should be rejected:

Re: Wrapping classes

2005-09-23 Thread Jeremy Sanders
Peter Hansen wrote: Almost anything is possible in Python, though whether the underlying design idea is sound is a completely different question. (Translation: try the following pseudo-code, but I have my suspicions about whether what you're doing is a good idea. :-) ) What I'd like to do

Re: words relating to networks that I should probably know

2005-09-23 Thread Roel Schroeven
John Walton schreef: Hello, again. I'm back with my instant messenger project. My teacher has assigned us to write our papers, excluding the procedure, results, and conclusion. One of my topics is going to be networks. Does anyone know a list of words relating to networking/networks that

Re: Question About Logic In Python

2005-09-23 Thread Steve Holden
Terry Reedy wrote: Steve Holden [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Which is yet another reason why it makes absolutely no sense to apply arithmetic operations to Boolean values. Except for counting the number of true values. This and other legitimate uses of

minidom appendChild confusion

2005-09-23 Thread Marco
Hello! Can anyone explain why the following code does not work? (I'm using python2.4.) Cheers, Marco -- # the following code does _not_ work. # intended: put child-nodes as children to another node from xml.dom.minidom import Document doc = Document() node1 = doc.createElement('one') el1 =

Re: Wrapping classes

2005-09-23 Thread Diez B. Roggisch
Jeremy Sanders wrote: Peter Hansen wrote: Almost anything is possible in Python, though whether the underlying design idea is sound is a completely different question. (Translation: try the following pseudo-code, but I have my suspicions about whether what you're doing is a good idea. :-) )

Re: Perl's documentation come of age

2005-09-23 Thread Steve Holden
Mike wrote: Steve Holden [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Jim Hugunin's keynote speech at this year's PyCon was accompanied by a projection if his interactive interpreter session, and I know I wasn't alone in finding this a convincing example of Microsoft's (well,

Re: C#3.0 and lambdas

2005-09-23 Thread Ganesan Rajagopal
Fredrik == Fredrik Lundh [EMAIL PROTECTED] writes: Reinhold Birkenfeld wrote: And I think the discussion that followed proved your point perfectly Fredrik. Big discussion over fairly minor things, but no big picture. Where are the initiatives on the big stuff (common documentation format,

Re: Wrapping classes

2005-09-23 Thread Jeremy Sanders
Diez B. Roggisch wrote: It works - in python 2.4!! I tried subclassing dict, but my __getitem__-method wasn't called - most probably because it's a C-type, but I don't know for sure. Maybe someone can elaborate on that? Yes - I tried that (see thread below). Unfortunately it needs Python 2.4,

Re: How to show percentage

2005-09-23 Thread Steve Holden
Sen-Lung Chen wrote: Dear All: I have a question of show percentage. For example ,I want to show the percentage of 1/3 = 33.33% I use the 1*100/3 = 33 it is 33 not 33.33 , how to show the 33.33 % Thanks You should by now know enough answers. The easiest way to ensure that the result

how to pickle unpicklable objects

2005-09-23 Thread Guy Lateur
Hi all, I've been writing an application containing a lot of settings which can be changed by the user. I'm using wx.Config to read/write these settings (to the windows registry). This means I can only store strings, ints and floats. However, it would be very convenient if I could also store

Re: Anyone else getting posts back as email undeliverable bounces?

2005-09-23 Thread Steve Holden
I've even tried communicating with postmaster at all relevant domains, but such messages are either bounced or ignored, so I've just filtered that domain out. regards Steve Bengt Richter wrote: It seems lately all my posts have been coming back to me as bounced emails, and I haven't

ANN: Voidspace Updates - Jalopy, logintools, textmacros, downman (etc)

2005-09-23 Thread Fuzzyman
Hello All, There have been various updates to the Voidspace modules : Jalopy 0.6.0 http://www.voidspace.org.uk/python/cgi.shtml#jalopy A collaborative website designer (CGI). It uses Kupu (http://kupu.oscom.org ) the WYSIWYG HTML editor. This update moves to Kupu 1.3 and the pythonutils 0.2.2

Re: Wrapping classes

2005-09-23 Thread bruno modulix
Jeremy Sanders wrote: Diez B. Roggisch wrote: It works - in python 2.4!! I tried subclassing dict, but my __getitem__-method wasn't called - most probably because it's a C-type, but I don't know for sure. Maybe someone can elaborate on that? Yes - I tried that (see thread below).

Re: Wrapping classes

2005-09-23 Thread Jeremy Sanders
bruno modulix wrote: Could it work with a UserDict subclass ? Unfortunately not: Traceback (most recent call last): File test.py, line 17, in ? print eval(10 * a + b, globals(), l) TypeError: eval() argument 3 must be dict, not instance Thanks Jeremy -- Jeremy Sanders

Re: minidom appendChild confusion

2005-09-23 Thread Peter Otten
Marco wrote: Can anyone explain why the following code does not work? (I'm using python2.4.) # the following code does _not_ work. # intended: put child-nodes as children to another node from xml.dom.minidom import Document doc = Document() node1 = doc.createElement('one') el1 =

Re: Finding where to store application data portably

2005-09-23 Thread Steven D'Aprano
On Thu, 22 Sep 2005 19:09:28 +0400, en.karpachov wrote: There is an other way around: look at your home dir as if it is your settings dir and don't clutter it with files other than application config dot-files. Just make ~/files/, ~/bin/ ~/lib/ etc. for it. Do you put everything into /etc

Re: How to use a timer in Python?

2005-09-23 Thread Nick Craig-Wood
Nico Grubert [EMAIL PROTECTED] wrote: There is no cronjob anymore now. I just need to check if there is a lock file. How would you modify my short program to avoid the situation Ie someone can get in there after you read the directory but before you create the file.? You can't do it

Re: minidom appendChild confusion

2005-09-23 Thread Marco
That's it. Thank you very much! Marco -- http://mail.python.org/mailman/listinfo/python-list

Re: What is self?

2005-09-23 Thread Roy Smith
Ron Adam [EMAIL PROTECTED] wrote: You can actually call it anything you want but self is sort of a tradition. That's true, but I think needs to be said a bit more emphatically. There's no reason to call it anything other than self and a newcomer to the language would be well advised to not

Re: C#3.0 and lambdas

2005-09-23 Thread A.M. Kuchling
On Fri, 23 Sep 2005 15:46:54 +0530, Ganesan Rajagopal [EMAIL PROTECTED] wrote: I agree. I am a lurker in this list and the python-devel list and I've also noticed that increasingly big discussions happen over fairly minor things. Python's DB API is still stuck at 2.0 and we can't even

Re: Alternatives to Stackless Python?

2005-09-23 Thread Olivier Dormond
Christophe wrote: [EMAIL PROTECTED] a écrit : I found LGT http://lgt.berlios.de/ but it didn't seem as if the NanoThreads module had the same capabilites as stackless. What specific capabilities of Stackless are you looking for, that are missing from NanoThreads? Capabilities of the

File processing

2005-09-23 Thread Gopal
Hello, I'm Gopal. I'm looking for a solution to the following problem: I need to create a text file config.txt having some parameters. I'm thinking of going with this format by having Param Name - value. Note that the value is a string/number; something like this: PROJECT_ID = E4208506

replacments for stdio?

2005-09-23 Thread Ido . Yehieli
hi, i was wondering if anyone have written a GUI module that can function as a replacment for stdin/stdout? ie. has a file like interface, by which one could just assaign it to sys.stdout or sys.stdin and have all your prints and raw_inputs and other such things shown in a GUI window? Thanks

Re: File processing

2005-09-23 Thread [EMAIL PROTECTED]
The ConfigParser class is designed for this task, see http://docs.python.org/lib/module-ConfigParser.html -- http://mail.python.org/mailman/listinfo/python-list

Using distutils 2.4 for python 2.3

2005-09-23 Thread Noam Raphael
Hello, I want to distribute a package. It's compatible with Python 2.3. Is there a way to use distutils 2.4 feature package_data, while maintaining the distribution compatible with python 2.3 ? Thanks, Noam Raphael -- http://mail.python.org/mailman/listinfo/python-list

Re: Sniffing Text Files

2005-09-23 Thread Steven D'Aprano
On Fri, 23 Sep 2005 01:20:49 -0300, David Pratt wrote: Hi. I have files that I will be importing in at least four different plain text formats, one of them being tab delimited format, a couple being token based uses pipes (but not delimited with pipes), another being xml. There will likely

Re: What is self?

2005-09-23 Thread Rick Wotnaz
Roy Smith [EMAIL PROTECTED] wrote in news:[EMAIL PROTECTED]: Ron Adam [EMAIL PROTECTED] wrote: You can actually call it anything you want but self is sort of a tradition. That's true, but I think needs to be said a bit more emphatically. There's no reason to call it anything other than

Re: Alternatives to Stackless Python?

2005-09-23 Thread Christophe
Olivier Dormond a écrit : Christophe wrote: [EMAIL PROTECTED] a écrit : I found LGT http://lgt.berlios.de/ but it didn't seem as if the NanoThreads module had the same capabilites as stackless. What specific capabilities of Stackless are you looking for, that are missing from

Re: how to pickle unpicklable objects

2005-09-23 Thread Ido . Yehieli
interesting. usually the [pickle | cpickle | marshal] modules should handle such things -- http://mail.python.org/mailman/listinfo/python-list

Re: File processing

2005-09-23 Thread Jeremy Jones
Gopal wrote: Hello, I'm Gopal. I'm looking for a solution to the following problem: I need to create a text file config.txt having some parameters. I'm thinking of going with this format by having Param Name - value. Note that the value is a string/number; something like this: PROJECT_ID =

Re: File processing

2005-09-23 Thread Gopal
Thanks for the reference. However, I'm not understanding how to use it. Could you please provide with an example? Like I open the file, read line and give it to parser? Please help me. -- http://mail.python.org/mailman/listinfo/python-list

Re: File processing

2005-09-23 Thread Peter Hansen
Gopal wrote: Hello, I'm Gopal. I'm looking for a solution to the following problem: I need to create a text file config.txt having some parameters. I'm thinking of going with this format by having Param Name - value. Note that the value is a string/number; something like this:

Re: What is self?

2005-09-23 Thread Jeff Schwab
Rick Wotnaz wrote: Roy Smith [EMAIL PROTECTED] wrote in news:[EMAIL PROTECTED]: Ron Adam [EMAIL PROTECTED] wrote: You can actually call it anything you want but self is sort of a tradition. That's true, but I think needs to be said a bit more emphatically. There's no reason to call it

Re: Character Sequence Generation

2005-09-23 Thread Jeff Schwab
Pedro Werneck wrote: On Thu, 22 Sep 2005 23:26:58 -0400 Jeff Schwab [EMAIL PROTECTED] wrote: What's the best way to generate a sequence of characters in Python? I'm looking for something like this Perl code: 'a' .. 'z' . If you want arbitrary sequences, you may use something like:

Re: File processing

2005-09-23 Thread Gopal
Thank you very much. That works!!! -- http://mail.python.org/mailman/listinfo/python-list

Re: Using distutils 2.4 for python 2.3

2005-09-23 Thread George Sakkis
Noam Raphael [EMAIL PROTECTED] wrote: Hello, I want to distribute a package. It's compatible with Python 2.3. Is there a way to use distutils 2.4 feature package_data, while maintaining the distribution compatible with python 2.3 ? Thanks, Noam Raphael You could distribute the whole 2.4

Re: File processing

2005-09-23 Thread Jeremy Jones
Gopal wrote: Thanks for the reference. However, I'm not understanding how to use it. Could you please provide with an example? Like I open the file, read line and give it to parser? Please help me. I had thought of recommending what Peter Hansen recommended - just importing the text you

ANN: python-ldap-2.0.10

2005-09-23 Thread Michael Ströder
Find a new release of python-ldap: http://python-ldap.sourceforge.net/ python-ldap provides an object-oriented API to access LDAP directory servers from Python programs. It mainly wraps the OpenLDAP 2.x libs for that purpose. Additionally it contains modules for other LDAP-related stuff (e.g.

Re: Using distutils 2.4 for python 2.3

2005-09-23 Thread Fredrik Lundh
Noam Raphael wrote: I want to distribute a package. It's compatible with Python 2.3. Is there a way to use distutils 2.4 feature package_data, while maintaining the distribution compatible with python 2.3 ? you can enable new metadata fields in older versions by assigning to the

Re: C#3.0 and lambdas

2005-09-23 Thread Richie Hindle
[amk] Similar things happen on the catalog SIG: people suggest, or even implement, an automatic package management system, But bring up the question of whether it should be called PyPI or Cheeseshop or the Catalog, and *everyone* can make a suggestion. This is known as the bike shed effect:

Re: C#3.0 and lambdas

2005-09-23 Thread Mike Meyer
A.M. Kuchling [EMAIL PROTECTED] writes: Agreed; python-dev has gotten pretty boring with all the endless discussions over some minor point. Of course, it's much easier and lower-effort to propose a syntax or nitpick a small point issue than to tackle a big complicated issue like static

Re: Wrapping classes

2005-09-23 Thread Colin J. Williams
Jeremy Sanders wrote: Peter Hansen wrote: Almost anything is possible in Python, though whether the underlying design idea is sound is a completely different question. (Translation: try the following pseudo-code, but I have my suspicions about whether what you're doing is a good idea. :-) )

Re: Question About Logic In Python

2005-09-23 Thread Terry Hancock
On Thursday 22 September 2005 07:09 pm, Ron Adam wrote: Terry Hancock wrote: On Thursday 22 September 2005 12:26 pm, Ron Adam wrote: True and True True Also makes sense (and this is indeed what happens). Only because True is the last value here. ;-) Nope, works for False, too:

Re: Wrapping classes

2005-09-23 Thread Jeremy Sanders
Colin J. Williams wrote: Could you not have functions a and b each of which returns a NumArray instance? Your expression would then be something like a(..)+2*b(..). The user enters the expression (yes - I'm aware of the possible security issues), as it is a scientific application. I don't

Re: Sniffing Text Files

2005-09-23 Thread David Pratt
Thanks Mike for your reply. I am not aware of libmagic and will look to see what it provides. As far as your first suggestion, this is what I have been looking at - probably a combination regex and readlines or similar but trying to get a better sense of best sort of approach more or less.

Re: Sniffing Text Files

2005-09-23 Thread skip
David I realize CSV module has a sniffer but it is something that is David limited more or less to delimited files. Sure. How about: def sniff(fname): if open(fname).read(4) == xml: return xml else: # assume csv - use its sniffer to

Re: C#3.0 and lambdas

2005-09-23 Thread Ganesan Rajagopal
A M Kuchling [EMAIL PROTECTED] writes: The group of committers is a diverse group of people, and not every one of them uses a relational database; that effort would be better done on the DB-SIG mailing list, because the people there presumably do all use an RDBMS. (Now, if you wanted to

Productivity and economics at software development

2005-09-23 Thread Adriano Monteiro
Hi folks, I'm making a little research project about programming languages e their respective IDEs. The goal is to trace each language silhouettes, where it fits better, their goods/bads and the costs of developing in this language. It's easy to find projects that doesn't worked as

Re: C#3.0 and lambdas

2005-09-23 Thread Steven Bethard
Erik Wilsher wrote: And I think the discussion that followed proved your point perfectly Fredrik. Big discussion over fairly minor things, but no big picture. Where are the initiatives on the big stuff (common documentation format, improved build system, improved web modules, reworking

Re: Using distutils 2.4 for python 2.3

2005-09-23 Thread Noam Raphael
Fredrik Lundh wrote: you can enable new metadata fields in older versions by assigning to the DistributionMetadata structure: try: from distutils.dist import DistributionMetadata DistributionMetadata.package_data = None except: pass setup(

Re: What is self?

2005-09-23 Thread Sion Arrowsmith
Rick Wotnaz [EMAIL PROTECTED] wrote: I've long thought that Guido missed an opportunity by not choosing to use 'i' as the instance identifier, and making it a reserved word. For one thing, it would resonate with the personal pronoun 'I', and so carry essentially the same meaning as 'self'. It

Re: Productivity and economics at software development

2005-09-23 Thread Diez B. Roggisch
I get this: Mod_python error: PythonHandler mod_python.publisher Traceback (most recent call last): File /usr/lib/python2.3/site-packages/mod_python/apache.py, line 299, in HandlerDispatch result = object(req) File /usr/lib/python2.3/site-packages/mod_python/publisher.py, line 136, in

Re: What is self?

2005-09-23 Thread Terry Hancock
On Friday 23 September 2005 07:11 am, Rick Wotnaz wrote: I've long thought that Guido missed an opportunity by not choosing to use 'i' as the instance identifier, and making it a reserved word. For one thing, it would resonate with the personal pronoun 'I', and so carry essentially the same

Re: Productivity and economics at software development

2005-09-23 Thread Scott David Daniels
Adriano Monteiro wrote: Hi folks, I'm making a little research project about programming languages e their respective IDEs. The goal is to trace each language silhouettes, where it fits better, their goods/bads and the costs of developing in this language. What do you consider the IDE

Single type for __builtins__ in Py3.0

2005-09-23 Thread Collin Winter
Hallo all, As it currently stands, the type of the global __builtins__ differs depending on whether you're in the __main__ namespace (__builtins__ is a module) or not (its a dict). I was recently tripped up by this discrepancy, and googling the issue brings up half-a-dozen or so c.l.p threads

Re: Sniffing Text Files

2005-09-23 Thread Mike Meyer
David Pratt [EMAIL PROTECTED] writes: Thanks Mike for your reply. I am not aware of libmagic and will look to see what it provides. and ... Skip Montanaro [EMAIL PROTECTED] writes: You can also run the file(1) command and see what it says. I seem to recall someone asking about the

Re: Sniffing Text Files

2005-09-23 Thread David Pratt
Hi Skip. Thank you for your reply. This is helpful and I am glad I put this to the list. There are some really good ideas that will help me come up with something good to use. Regards, David On Friday, September 23, 2005, at 11:14 AM, [EMAIL PROTECTED] wrote: David I realize CSV module

Re: Sniffing Text Files

2005-09-23 Thread David Pratt
Thanks Mike this is really great! Regards, David On Friday, September 23, 2005, at 11:55 AM, Mike Meyer wrote: David Pratt [EMAIL PROTECTED] writes: Thanks Mike for your reply. I am not aware of libmagic and will look to see what it provides. and ... Skip Montanaro [EMAIL PROTECTED]

Re: time challenge

2005-09-23 Thread nephish
sorry about that, i got a message in my inbox that said that the post was rejected so i tried it from my email client. wont happen again. shawn -- http://mail.python.org/mailman/listinfo/python-list

NaN Vs None

2005-09-23 Thread Peck, Jon
In choosing a way to represent a value of no information for a float, would it be better to use NaN or None? None has the advantage of standard behavior across platforms, but NaN seems to propagate more easily at least on Windows. For example, NaN+1 = NaN but None+1 raises an

Re: optimizing a program that just shuffles data, a bit like cat...

2005-09-23 Thread Oracle
On Fri, 23 Sep 2005 01:16:46 +, Dan Stromberg wrote: ...but with much bigger blocksizes, and with a netcat-like ability to use sockets. Try using psyco and see if that helps. Also, sometimes smaller blocks are better than large blocks. Try using smaller block sizes and see if that

Config parser module

2005-09-23 Thread qqcq6s59
Hi all I am a newbie and I just saw a ongoing thread on Fileprocessing which talks abt config parser. I have writen many pyhton program to parse many kind of text files by using string module and regex. But after reading that config parser thread I feel stunned. Can somebody tell me some intro

Re: What is self?

2005-09-23 Thread Peter
Terry Hancock wrote: On Friday 23 September 2005 07:11 am, Rick Wotnaz wrote: I've long thought that Guido missed an opportunity by not choosing to use 'i' as the instance identifier, and making it a reserved word. For one thing, it would resonate with the personal pronoun 'I', and so

Re: What is self?

2005-09-23 Thread Rick Wotnaz
Terry Hancock [EMAIL PROTECTED] wrote in news:[EMAIL PROTECTED]: On Friday 23 September 2005 07:11 am, Rick Wotnaz wrote: I've long thought that Guido missed an opportunity by not choosing to use 'i' as the instance identifier, and making it a reserved word. For one thing, it would resonate

Re: Config parser module

2005-09-23 Thread Dale Strickland-Clark
The Config Parser module is for extracting data from and writing to a specific format of file, generally known as a config file. As explained in the documentation, a config file is in the same format as .ini files frequently found on windows - especially used by older software. It is a very handy

Re: Single type for __builtins__ in Py3.0

2005-09-23 Thread Michael Hoffman
Collin Winter wrote: If possible, I'd like to see this go in before 3.0. +1 -- Michael Hoffman -- http://mail.python.org/mailman/listinfo/python-list

Re: optimizing a program that just shuffles data, a bit like cat...

2005-09-23 Thread Dan Stromberg
On Fri, 23 Sep 2005 10:18:47 -0500, Oracle wrote: On Fri, 23 Sep 2005 01:16:46 +, Dan Stromberg wrote: [quoted text muted] Try using psyco and see if that helps. Also, sometimes smaller blocks are better than large blocks. Try using smaller block sizes and see if that helps. I

Re: NaN Vs None

2005-09-23 Thread François Pinard
[Peck, Jon] In choosing a way to represent a value of no information for a float, would it be better to use NaN or None? None has the advantage of standard behavior across platforms, but NaN seems to propagate more easily – at least on Windows. [...] What I do for these things is creating

Re: What is self?

2005-09-23 Thread Terry Hancock
On Friday 23 September 2005 10:42 am, Peter wrote: Terry Hancock wrote: How exactly is that? Anybody who uses i as a variable name for anything other than an innermost loop index is a sick and twisted code sadist. Agreed, though to say code sadist is a little hard don't ya think? ;) I

Re: What is self?

2005-09-23 Thread Terry Hancock
On Friday 23 September 2005 10:41 am, Rick Wotnaz wrote: Oh, 'ix' would be fine. Single-letter loop counters are also semi- fine if that is in fact their only use. It too-frequently happens that at some point the handy 'i' identifier is used outside the loop (for another placeholder), and

Re: Config parser module

2005-09-23 Thread Larry Bates
ConfigParser is for parsing configuration files of the format: [section1] option1=information option2=information . . . optionN=information [section2] option1=information option2=information . . . optionN=informattion Your data doesn't fit that format. Looks to me like you should write a small

  1   2   >