Re: [Python-Dev] runpy.py

2009-08-26 Thread Nick Coghlan
Alexander Belopolsky wrote: > Take a look at two PEPs referenced in runpy doc, > http://docs.python.org/3.1/library/runpy.html : > > PEP 338 - Executing modules as scripts > PEP written and implemented by Nick Coghlan. > PEP 366 - Main module explicit relative imports > PEP written and implemented

Re: [Python-Dev] Excluding the current path from module search path?

2009-08-26 Thread Nick Coghlan
Chris Withers wrote: > Hi All, > > I'm being bitten by this issue: > > http://bugs.python.org/issue1734860 > > I'm not sure I agree with Daniel's closing of it so thought I'd ask here... > > Am I right in thinking that the general idea is that "the current > working directory at the time of inv

[Python-Dev] copyright ownership

2009-08-26 Thread Antoine Pitrou
Guido van Rossum python.org> writes: > > Are you a lawyer? Do you know the legal history of Python > distributions and the US export laws? It's not so easy -- for one, the > PSF (a US foundation) owns the copyright. Does it? As far as I understand, the contributor agreement is not a copyright tr

Re: [Python-Dev] copyright ownership

2009-08-26 Thread Guido van Rossum
On Wed, Aug 26, 2009 at 7:44 AM, Antoine Pitrou wrote: > Guido van Rossum python.org> writes: >> >> Are you a lawyer? Do you know the legal history of Python >> distributions and the US export laws? It's not so easy -- for one, the >> PSF (a US foundation) owns the copyright. > > Does it? As far a

Re: [Python-Dev] PEP 3144: IP Address Manipulation Librar y for the Python Standard Library

2009-08-26 Thread Antoine Pitrou
DrKJam gmail.com> writes: > netaddr employs a simple variant of the GoF Strategy design pattern (with added Python sensibility). It would be nice if you could avoid employing this kind of acronyms without explaining them. Not everybody drinks the design pattern kool-aid. (Google tells me that GoF

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread Martin v. Löwis
>> netaddr employs a simple variant of the GoF Strategy design pattern (with > added Python sensibility). > > It would be nice if you could avoid employing this kind of acronyms without > explaining them. Not everybody drinks the design pattern kool-aid. > (Google tells me that GoF seems to mean "

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread Ben Finney
Antoine Pitrou writes: > DrKJam gmail.com> writes: > > netaddr employs a simple variant of the GoF Strategy design pattern (with > added Python sensibility). > > It would be nice if you could avoid employing this kind of acronyms > without explaining them. Not everybody drinks the design pattern

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread Antoine Pitrou
Martin v. Löwis v.loewis.de> writes: > [...] > Then, class IPAddress has a method reverse_dns, which is defined > as > > def reverse_dns(self): > """The reverse DNS lookup record for this IP address""" > return self._module.int_to_arpa(self._value) > > So IPv4 addresses and I

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread Martin v. Löwis
>> DrKJam gmail.com> writes: >>> netaddr employs a simple variant of the GoF Strategy design pattern (with >> added Python sensibility). >> >> It would be nice if you could avoid employing this kind of acronyms >> without explaining them. Not everybody drinks the design pattern >> kool-aid. > > A

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread Michael Foord
Antoine Pitrou wrote: DrKJam gmail.com> writes: netaddr employs a simple variant of the GoF Strategy design pattern (with added Python sensibility). It would be nice if you could avoid employing this kind of acronyms without explaining them. Not everybody drinks the design pattern koo

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread Antoine Pitrou
Michael Foord voidspace.org.uk> writes: > > Really? Discussing the GoF design patterns by name seems to be prevalent > amongst the programmers I know (yourself excluded of course...). Ah? I still haven't understood what "Gang of Four" is supposed to be, however. Is it a design pattern? Besides

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread Michael Foord
Antoine Pitrou wrote: Michael Foord voidspace.org.uk> writes: Really? Discussing the GoF design patterns by name seems to be prevalent amongst the programmers I know (yourself excluded of course...). Ah? I still haven't understood what "Gang of Four" is supposed to be, however. Is it

[Python-Dev] 3to2 0.1 alpha 1 released

2009-08-26 Thread Joe Amenta
Hello all, I have released the first alpha version of 3to2 after finishing it for my Google Summer of Code 2009(tm) project. You can get the tarball for this release at http://bitbucket.org/amentajo/lib3to2/downloads/3to2_0.1-alpha1.tar.gz. This requires python 2.7, because it requires a newer ve

[Python-Dev] No 2.4.7 release

2009-08-26 Thread Martin v. Löwis
I once announced that I would be working on releasing 2.4.7 this month. However, since no patches have been committed to 2.4.6, there is little point in making a release. As 2.4 is nearing its end-of-life soon, there likely won't be any 2.4.7 release. Python 2.5 has seen only two patches since 2.

Re: [Python-Dev] 3to2 0.1 alpha 1 released

2009-08-26 Thread Martin v. Löwis
> I have released the first alpha version of 3to2 after finishing it for > my Google Summer of Code 2009(tm) project. Congratulations! I understand SoC is basically over, but I would still like to request two things: - can you please register it with PyPI? - can you please announce/report some pl

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread skip
Martin> I think it's too early to tell. It may be that they have not yet Martin> achieved their purpose - just let's wait fifty more years (and Martin> I'm only half-joking). So what you're really saying is we only have to wait 25 years... Skip ___

Re: [Python-Dev] 3to2 0.1 alpha 1 released

2009-08-26 Thread Joe Amenta
On Wed, Aug 26, 2009 at 4:26 PM, "Martin v. Löwis" wrote: > > I have released the first alpha version of 3to2 after finishing it for > > my Google Summer of Code 2009(tm) project. > > Congratulations! I understand SoC is basically over, but I would still > like to request two things: > > - can you

Re: [Python-Dev] Excluding the current path from module search path?

2009-08-26 Thread Chris Withers
Nick Coghlan wrote: The details of the sys.path manipulation at program startup are documented here: http://docs.python.org/using/cmdline.html#command-line The directory prepended to sys.path is based on the code executed by the command line. It's more subtle than that though... The OP in htt

Re: [Python-Dev] PEP 3144: IP Address Manipulation Library for the Python Standard Library

2009-08-26 Thread DrKJam
I've started a very basic (work in progress) entry on the netaddr wiki to track various aspects of this discussion that might not be in a format suitable for publishing to the list or are too lengthy. It will also allow my ascii art diagrams to render correctly ;-) http://code.google.com/p/netaddr

Re: [Python-Dev] deleting setdefaultencoding iin site.py is evil

2009-08-26 Thread Chris Withers
exar...@twistedmatrix.com wrote: The ability to change the default encoding is a misfeature. There's essentially no way to write correct Python code in the presence of this feature. How so? If every single piece of text in your project is encoded in a superset of ascii (such as utf-8), why w

Re: [Python-Dev] deleting setdefaultencoding iin site.py is evil

2009-08-26 Thread Chris Withers
M.-A. Lemburg wrote: Let's look at this from another angle: sys.setdefaultencoding() is only made available for use in site.py. ...see this: http://mail.python.org/pipermail/python-dev/2009-August/091391.html I would like to use sitecustomize.py for all the very good reasons given in this t

Re: [Python-Dev] deleting setdefaultencoding iin site.py is evil

2009-08-26 Thread Chris Withers
Guido van Rossum wrote: In retrospect, it should have been called sys._setdefaultencoding(). That sends an extra signal that it's not meant for general use. Crazy idea: how about mutating it into sys._setdefaultencoding rather than deleting it? Chris -- Simplistix - Content Management, Batc

Re: [Python-Dev] Problems with events in a numeric keyboard

2009-08-26 Thread Greg Ewing
Martin Zugnoni wrote: when I press the triple zero key once, I receive three events from the single zero key. I need to make a disctintion between these keys Sounds like you can't, except perhaps by detecting three '0' key events arriving at almost the same time. -- Greg __

Re: [Python-Dev] deleting setdefaultencoding iin site.py is evil

2009-08-26 Thread Martin v. Löwis
>> The ability to change the default encoding is a misfeature. There's >> essentially no way to write correct Python code in the presence of >> this feature. > > How so? If every single piece of text in your project is encoded in a > superset of ascii (such as utf-8), why would this be a problem?

Re: [Python-Dev] deleting setdefaultencoding iin site.py is evil

2009-08-26 Thread Martin v. Löwis
>> In retrospect, it should have been called sys._setdefaultencoding(). >> That sends an extra signal that it's not meant for general use. > > Crazy idea: how about mutating it into sys._setdefaultencoding rather > than deleting it? Please don't post crazy ideas unless you really mean them. This