Re: [Python-Dev] test_sys failures

2008-01-07 Thread Guido van Rossum
On Dec 21, 2007 12:05 AM, Nick Coghlan <[EMAIL PROTECTED]> wrote: > Guido van Rossum wrote: > > When I build from scratch and run most tests (regrtest.py -uall) I get > > some strange failures with test_sys.py: > > > > test test_sys failed -- Traceback (most recent call last): > > File "/usr/loca

[Python-Dev] New Developer

2008-01-07 Thread Mark Dickinson
Hello all, I've recently been granted commit privileges; so, following the usual protocol, here's a quick introduction. I'm a mathematician by day; my degree is in number theory, but five summers of Fortran 77 programming and two semesters of teaching numerical analysis have given me a taste for

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Brett Cannon
On Jan 7, 2008 2:24 PM, Raymond Hettinger <[EMAIL PROTECTED]> wrote: > >> And then extend this to any other > >> package that we consider creating? Otherwise leave it out? How would > >> that follow for sqlite since that is not going to get any shorter > >> thanks to a package? Should it still go

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Brett Cannon
On Jan 7, 2008 3:47 PM, Guido van Rossum <[EMAIL PROTECTED]> wrote: > On Jan 7, 2008 12:56 PM, Brett Cannon <[EMAIL PROTECTED]> wrote: > > OK. So an html package could have htmllib for its __init__ (or > > html.lib), and then have html.entities and html.parser for > > htmlentitydefs and HTMLParser,

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Christian Heimes
Paul Moore wrote: > What would be used on Windows? It's likely to be of marginal use on > Windows, but an appropriate equivalent should be defined. Possibly > just replace ~ with %USERPROFILE%. I'd argue against anything under > %APPDATA% as that directory is hidden. No, we shouldn't mess with the

Re: [Python-Dev] Backport PEP 3129: Class Decorators

2008-01-07 Thread Christian Heimes
Raymond Hettinger wrote: > This seems like something that could reasonably be added to Py2.6. +1 from me PEP 3107 (function annotation), PEP 3104 (nonlocal) and PEP 3132 (extended iterable unpacking: a, *b = 1,2,3) are IMHO other useful feature for 2.6. nonlocal would require a __future__ import.

[Python-Dev] Backport PEP 3129: Class Decorators

2008-01-07 Thread Raymond Hettinger
This seems like something that could reasonably be added to Py2.6. Raymond ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mai

Re: [Python-Dev] [python] Re: pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Michael Foord
Paul Moore wrote: > On 07/01/2008, Tristan Seligmann <[EMAIL PROTECTED]> wrote: > >>> D'oh, yes of course. So make that: >>> >>> ~/.python/lib/pythonX.Y/site-packages >>> >> In that case how about: >> >> ~/.local/lib/pythonX.Y/site-packages >> >> or: >> >> ~/local/lib/pythonX.Y/site-pack

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Guido van Rossum
On Jan 7, 2008 12:56 PM, Brett Cannon <[EMAIL PROTECTED]> wrote: > OK. So an html package could have htmllib for its __init__ (or > html.lib), and then have html.entities and html.parser for > htmlentitydefs and HTMLParser, respectively. I'd be very reluctant to have more "asymmetric" packages lik

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Andrew McNamara
>The best existing indicator we have is the organization of the docs for >the standard library. I, for one, have a hell of a difficult time finding >modules via the "organized" table of contents in the Library Reference. >Instead, I always go the the Global Module Index where the somewhat flat >nam

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Paul Moore
On 07/01/2008, Tristan Seligmann <[EMAIL PROTECTED]> wrote: > > D'oh, yes of course. So make that: > > > > ~/.python/lib/pythonX.Y/site-packages > > In that case how about: > > ~/.local/lib/pythonX.Y/site-packages > > or: > > ~/local/lib/pythonX.Y/site-packages What would be used on Windows? It's

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Tristan Seligmann
* Barry Warsaw <[EMAIL PROTECTED]> [2008-01-07 16:01:42 -0500]: > On Jan 7, 2008, at 11:37 AM, Phillip J. Eby wrote: > > >> Python automatically adds ~/.python/site-packages to sys.path; this > >> is > >> added /before/ the system site-packages file. An open question is > >> whether it needs t

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Phillip J. Eby
At 05:24 PM 1/7/2008 -0500, Raymond Hettinger wrote: >The best existing indicator we have is the organization of the docs >for the standard library. I, for one, have a hell of a difficult >time finding modules via the "organized" table of contents in the >Library Reference. Instead, I always go

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Paul Moore
On 07/01/2008, Raymond Hettinger <[EMAIL PROTECTED]> wrote: > It is my hope that there will be a great deal of restraint in the effort to > group modules into > packages in Py3.0. +1 > The best existing indicator we have is the organization of the docs for the > standard library. > I, for one,

[Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Raymond Hettinger
>> And then extend this to any other >> package that we consider creating? Otherwise leave it out? How would >> that follow for sqlite since that is not going to get any shorter >> thanks to a package? Should it still go into the package for >> organizational purposes? > If you're asking me, the

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Fred Drake
On Jan 7, 2008, at 3:56 PM, Brett Cannon wrote: > OK. So an html package could have htmllib for its __init__ (or > html.lib), and then have html.entities and html.parser for > htmlentitydefs and HTMLParser, respectively. Actually, I'd be inclined not to have both HTMLParser and htmllib (regardle

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Barry Warsaw
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Jan 7, 2008, at 11:30 AM, M.-A. Lemburg wrote: >> Open question: should we add yet another environment variable to >> control >> this? It's pretty typical for apps to expose such a thing so that >> the >> base directory (e.g. ~/.python) can be

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Barry Warsaw
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Jan 7, 2008, at 11:37 AM, Phillip J. Eby wrote: >> Python automatically adds ~/.python/site-packages to sys.path; this >> is >> added /before/ the system site-packages file. An open question is >> whether it needs to go at the front of the list.

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Brett Cannon
On Jan 7, 2008 12:40 PM, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > On Jan 7, 2008 12:19 PM, Brett Cannon <[EMAIL PROTECTED]> wrote: > > On Jan 6, 2008 8:28 PM, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > > On Jan 6, 2008 7:23 PM, Phillip J. Eby <[EMAIL PROTECTED]> wrote: > > > > At 04:23

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Guido van Rossum
On Jan 7, 2008 12:19 PM, Brett Cannon <[EMAIL PROTECTED]> wrote: > On Jan 6, 2008 8:28 PM, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > On Jan 6, 2008 7:23 PM, Phillip J. Eby <[EMAIL PROTECTED]> wrote: > > > At 04:23 PM 1/6/2008 -0800, Guido van Rossum wrote: > > > >Regarding using common words,

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Brett Cannon
On Jan 6, 2008 8:28 PM, Guido van Rossum <[EMAIL PROTECTED]> wrote: > On Jan 6, 2008 7:23 PM, Phillip J. Eby <[EMAIL PROTECTED]> wrote: > > At 04:23 PM 1/6/2008 -0800, Guido van Rossum wrote: > > >Regarding using common words, either the stdlib grabs these, or > > >*nobody* gets to use them (for fe

Re: [Python-Dev] [Python-3000] Rounding Decimals

2008-01-07 Thread Raymond Hettinger
[Aahz] > I have always thought that "quantize()" makes Decimal > confusing in the context of the other mechanisms that Python makes > available for other kinds of numbers. No doubt, the spec made a number of choices that are obvious only if you work at IBM. And, there is no doubt, the module has

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Phillip J. Eby
At 11:24 AM 1/7/2008 -0500, Barry Warsaw wrote: >-BEGIN PGP SIGNED MESSAGE- >Hash: SHA1 > >On Jan 7, 2008, at 10:12 AM, Guido van Rossum wrote: > > > On Jan 7, 2008 6:32 AM, Barry Warsaw <[EMAIL PROTECTED]> wrote: > >> On Jan 7, 2008, at 9:01 AM, M.-A. Lemburg wrote: > >>> We could easily r

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Phillip J. Eby
At 03:01 PM 1/7/2008 +0100, M.-A. Lemburg wrote: >On 2008-01-07 14:57, Fred Drake wrote: > > On Jan 7, 2008, at 7:48 AM, M.-A. Lemburg wrote: > >> Next, we add a per-user site-packages directory to the standard > >> sys.path, and then we could get rid of most of the setuptools > >> import and sys.p

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Phillip J. Eby
At 01:48 PM 1/7/2008 +0100, M.-A. Lemburg wrote: >I also don't like the import mechanism hackery that's being >used in setuptools to get namespace packages working. I believe you're mistaken: there is no import mechanism "hackery" in pkg_resources. (__path__ is a documented *hook*, not a hack, a

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread M.-A. Lemburg
On 2008-01-07 17:24, Barry Warsaw wrote: > On Jan 7, 2008, at 10:12 AM, Guido van Rossum wrote: > >> On Jan 7, 2008 6:32 AM, Barry Warsaw <[EMAIL PROTECTED]> wrote: >>> On Jan 7, 2008, at 9:01 AM, M.-A. Lemburg wrote: We could easily resolve that issue, if we add a per-user site-packages

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Barry Warsaw
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Jan 7, 2008, at 10:12 AM, Guido van Rossum wrote: > On Jan 7, 2008 6:32 AM, Barry Warsaw <[EMAIL PROTECTED]> wrote: >> On Jan 7, 2008, at 9:01 AM, M.-A. Lemburg wrote: >>> We could easily resolve that issue, if we add a per-user site- >>> packages

Re: [Python-Dev] [Python-3000] Rounding Decimals

2008-01-07 Thread Aahz
On Mon, Jan 07, 2008, Raymond Hettinger wrote: > [Jeffrey Yasskin] >> >> I am not building out the decimal API. I am adding enough methods to >> maintain the comment that "Decimal floating point objects share many >> properties with the other builtin numeric types such as float and int. >> All of

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Guido van Rossum
On Jan 7, 2008 6:32 AM, Barry Warsaw <[EMAIL PROTECTED]> wrote: > On Jan 7, 2008, at 9:01 AM, M.-A. Lemburg wrote: > > We could easily resolve that issue, if we add a per-user site-packages > > dir to sys.path in site.py (this is already done for Macs). > > +1. I've advocated that for years. I'm

Re: [Python-Dev] [Pydotorg] Do we need both Trac and Roundup?

2008-01-07 Thread Stephan Deibel
[EMAIL PROTECTED] wrote: > Do people think it would be worthwhile to merge the Trac tracker content > (the issue tracker that holds tickets related to the python.org website) > into the Roundup tracker (the issue tracker that holds tickets related to > Python the language)? While they are nominall

Re: [Python-Dev] [Python-3000] Rounding Decimals

2008-01-07 Thread Facundo Batista
2008/1/7, Raymond Hettinger <[EMAIL PROTECTED]>: > Arghh! You seem hell-bent on jamming this in. Please leave the > decimal module alone. It does *not* need both a round() method > and a quantize() method. Question. I'm so used to quantize that I don't care. And I'm, in general, -0 to adding

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Barry Warsaw
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Jan 7, 2008, at 9:01 AM, M.-A. Lemburg wrote: > We could easily resolve that issue, if we add a per-user site-packages > dir to sys.path in site.py (this is already done for Macs). +1. I've advocated that for years. - -Barry -BEGIN PGP SIGN

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Fred Drake
On Jan 7, 2008, at 7:48 AM, M.-A. Lemburg wrote: > Next, we add a per-user site-packages directory to the standard > sys.path, and then we could get rid of most of the setuptools > import and sys.path hackery, making it a lot cleaner. PYTHONPATH already provides this functionality. I see no need

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread M.-A. Lemburg
On 2008-01-07 14:57, Fred Drake wrote: > On Jan 7, 2008, at 7:48 AM, M.-A. Lemburg wrote: >> Next, we add a per-user site-packages directory to the standard >> sys.path, and then we could get rid of most of the setuptools >> import and sys.path hackery, making it a lot cleaner. > > > PYTHONPATH a

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread M.-A. Lemburg
On 2008-01-06 16:33, Christian Heimes wrote: > Hello! > > We are discussing name space packages on the stdlib reorg list. For > Python 3.0 we plan to organize the packages by purpose, e.g. put all > database related packages like sqlite and shelve in a 'databases' name > space. Regardless of whet

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Oleg Broytmann
On Sun, Jan 06, 2008 at 04:23:59PM -0800, Guido van Rossum wrote: > I don't want "py" or "python" to be > part of the stdlib package namespace. *If* (part of) the stdlib has to > live under a single distinguished name, pick something like "std" or > "core". When I'm using Python I already know I'm

Re: [Python-Dev] pkgutil, pkg_resource and Python 3.0 name space packages

2008-01-07 Thread Paul Moore
On 07/01/2008, Guido van Rossum <[EMAIL PROTECTED]> wrote: > There seems to be a misunderstanding. This is *not* going to happen > for standard library package names. I'm fine with inventing mechanisms > to allow 3rd party packages to beo cobbled together from multiple > contributions (it would see

Re: [Python-Dev] Rounding Decimals

2008-01-07 Thread Raymond Hettinger
[Jeffrey Yasskin] > I always like to have a patch around because abstract discussions, > even (especially?) on simple topics, have a tendency to run off into > the weeds. A patch keeps things focused and moving forward. Please recognize that our little system of patches and newsgroup discussions i

Re: [Python-Dev] Rounding Decimals

2008-01-07 Thread Jeffrey Yasskin
On Jan 6, 2008 10:51 PM, Raymond Hettinger <[EMAIL PROTECTED]> wrote: > [Jeffrey Yasskin] > >> > I'm not > >> > sure exactly what you're objecting to. Could you be more precise? > >> > >> You note said: "I'll implement Context.round() in a separate patch. > >> Comment away." > > > > Oh, sorry for