Re: [Python-3000] Implementing % formatting in terms of str.format()

2008-04-09 Thread skip
>> Is there a 2-to-3 fixer for % format? I scanned the fixes directly >> quickly but didn't see anything obvious. Benjamin> I believe the only reason that % is even in 3.0 is that a 2to3 Benjamin> fixer couldn't be easily written for it. I find that kind of hard to believe (that

Re: [Python-3000] Implementing % formatting in terms of str.format()

2008-04-09 Thread Benjamin Peterson
On Wed, Apr 9, 2008 at 9:20 PM, <[EMAIL PROTECTED]> wrote: > > Is there a 2-to-3 fixer for % format? I scanned the fixes directly quickly > but didn't see anything obvious. I believe the only reason that % is even in 3.0 is that a 2to3 fixer couldn't be easily written for it. > > Skip > > > __

Re: [Python-3000] Implementing % formatting in terms of str.format()

2008-04-09 Thread skip
Is there a 2-to-3 fixer for % format? I scanned the fixes directly quickly but didn't see anything obvious. Skip ___ Python-3000 mailing list Python-3000@python.org http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.or

[Python-3000] properties on IOBase

2008-04-09 Thread Benjamin Peterson
Should IOBase's writeable, readable, and seekable methods have decorators like the closed method? -- Cheers, Benjamin Peterson ___ Python-3000 mailing list Python-3000@python.org http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://m

Re: [Python-3000] buildbot failure in ppc Debian unstable 3.0

2008-04-09 Thread Bill Janssen
> > I can't run the ssl tests with -unetwork on my machine. Could somebody > > please fix the test for me? > > > > Christian > > I see at least three "merges from the trunk" since I last touched it > in December. If you revert these (to Lib/ssl.py, Modules/_ssl.c, and > Lib/test/test_ssl.py), I'

Re: [Python-3000] Implementing % formatting in terms of str.format()

2008-04-09 Thread Eric Smith
Understood. Maybe I'll just use this technique to implement %b, and leave everything else alone. I'll investigate. Guido van Rossum wrote: > I think there are too many risks with this approach, especially given > that we're keeping % formatting mainly for backwards compatibility > reasons. Ther

Re: [Python-3000] Implementing % formatting in terms of str.format()

2008-04-09 Thread Guido van Rossum
I think there are too many risks with this approach, especially given that we're keeping % formatting mainly for backwards compatibility reasons. There will inevitably be corner cases where the conversion doesn't work exactly the same way as the old code or where the conversion is wrong for whateve

[Python-3000] Implementing % formatting in terms of str.format()

2008-04-09 Thread Eric Smith
I'm working on issue 2416, adding %b to % formatting (http://bugs.python.org/issue2416). It's really quite a pain, especially in 2.6 with int and long and str and unicode. I'm contemplating just making % formatting compute a new format string and call str.format (or obj.__format__, or somethin

Re: [Python-3000] buildbot failure in ppc Debian unstable 3.0

2008-04-09 Thread Bill Janssen
> I can't run the ssl tests with -unetwork on my machine. Could somebody > please fix the test for me? > > Christian I see at least three "merges from the trunk" since I last touched it in December. If you revert these (to Lib/ssl.py, Modules/_ssl.c, and Lib/test/test_ssl.py), I'll bet things wi

Re: [Python-3000] buildbot failure in ppc Debian unstable 3.0

2008-04-09 Thread Bill Janssen
> > I can't run the ssl tests with -unetwork on my machine. Could > > somebody please fix the test for me? > > Oeer. The write() issues are easily fixed w/ b''. Investigating the lack of > AsyncoreHTTPSServer, though, yielded quite significant differences between > the trunk and py3k versions

Re: [Python-3000] PEP: Cleaning out sys and the "interpreter" module

2008-04-09 Thread Guido van Rossum
On Wed, Apr 9, 2008 at 4:05 PM, Bill Janssen <[EMAIL PROTECTED]> wrote: > > That's not the Python spirit. The spirit is that *if* they support > > similar enough functionality the APIs should be named the same, in the > > same module, and have the same signature. E.g. the os module is built > >

Re: [Python-3000] PEP: Cleaning out sys and the "interpreter" module

2008-04-09 Thread Bill Janssen
> That's not the Python spirit. The spirit is that *if* they support > similar enough functionality the APIs should be named the same, in the > same module, and have the same signature. E.g. the os module is built > on this principle. Many APIs there are optional, but if they exist, > they have a k

Re: [Python-3000] r62195 - in python/trunk: Doc/c-api/file.rst Include/fileobject.h Lib/test/test_file.py Misc/NEWS Objects/fileobject.c

2008-04-09 Thread Gregory P. Smith
On Wed, Apr 9, 2008 at 4:10 AM, Antoine Pitrou <[EMAIL PROTECTED]> wrote: > > Christian wrote: > > > Make file objects as thread safe as the underlying libc FILE* > implementation. > > > close() will now raise an IOError if any operations on the file object > > > are currently in progress in other

Re: [Python-3000] Equality of range objects

2008-04-09 Thread Guido van Rossum
On Tue, Apr 8, 2008 at 11:45 PM, Anand Balachandran Pillai <[EMAIL PROTECTED]> wrote: > Still this seems like a bad thing to break backward compatibility with. That's not a very strong argument for Py3k. > Hopefully, this will be well documented at 3.0 release. Currently > that "whats new" page

Re: [Python-3000] Types and classes

2008-04-09 Thread Guido van Rossum
On Wed, Apr 9, 2008 at 8:47 AM, Neil Schemenauer <[EMAIL PROTECTED]> wrote: > Greg Ewing <[EMAIL PROTECTED]> wrote: > > There's something reassuring about the fact that things > > with no "obvious" textual representation stick out like > > a sore digit when you try to print them. I wouldn't like

Re: [Python-3000] Types and classes

2008-04-09 Thread Neil Schemenauer
Greg Ewing <[EMAIL PROTECTED]> wrote: > There's something reassuring about the fact that things > with no "obvious" textual representation stick out like > a sore digit when you try to print them. I wouldn't like > to lose that. I agree with this and support the status quo (i.e. repr(int) == str(i

Re: [Python-3000] [Python-checkins] buildbot failure in ppc Debian unstable 3.0

2008-04-09 Thread Trent Nelson
Regarding the recent test_ssl.py failures in py3k; I'm at a loss as to what the py3k version should look like in comparison to trunk. At the moment, there are pretty significant differences. I played around with just copying the trunk version into py3k and running 2to3, but that yielded signi

Re: [Python-3000] buildbot failure in ppc Debian unstable 3.0

2008-04-09 Thread Trent Nelson
> I can't run the ssl tests with -unetwork on my machine. Could > somebody please fix the test for me? Oeer. The write() issues are easily fixed w/ b''. Investigating the lack of AsyncoreHTTPSServer, though, yielded quite significant differences between the trunk and py3k versions of test_ssl

[Python-3000] r62195 - in python/trunk: Doc/c-api/file.rst Include/fileobject.h Lib/test/test_file.py Misc/NEWS Objects/fileobject.c

2008-04-09 Thread Antoine Pitrou
Christian wrote: > > Make file objects as thread safe as the underlying libc FILE* > > implementation. > > close() will now raise an IOError if any operations on the file object > > are currently in progress in other threads. > > > > Most code was written by Antoine Pitrou (pitrou). Additional

Re: [Python-3000] buildbot failure in ppc Debian unstable 3.0

2008-04-09 Thread Christian Heimes
[EMAIL PROTECTED] schrieb: > The Buildbot has detected a new failure of ppc Debian unstable 3.0. > Full details are available at: > > http://www.python.org/dev/buildbot/all/ppc%20Debian%20unstable%203.0/builds/771 > > Buildbot URL: http://www.python.org/dev/buildbot/all/ > > Buildslave for this

Re: [Python-3000] Equality of range objects

2008-04-09 Thread Anand Balachandran Pillai
I was quoting from the 3.0 a4 docs. It needs to be fixed then. Thanks --Anand On Wed, Apr 9, 2008 at 1:41 PM, Arnaud Delobelle <[EMAIL PROTECTED]> wrote: > On 09/04/2008, Anand Balachandran Pillai <[EMAIL PROTECTED]> wrote: > > > "range() now returns an iterator rather than a list... > No: ran

Re: [Python-3000] Equality of range objects

2008-04-09 Thread Arnaud Delobelle
On 09/04/2008, Anand Balachandran Pillai <[EMAIL PROTECTED]> wrote: > "range() now returns an iterator rather than a list... No: range() returns an iterable. -- Arnaud ___ Python-3000 mailing list Python-3000@python.org http://mail.python.org/mailman/l

Re: [Python-3000] Equality of range objects

2008-04-09 Thread Georg Brandl
Anand Balachandran Pillai schrieb: > Still this seems like a bad thing to break backward compatibility with. > However I cannot really provide a use-case apart from what Benjamin > has said -> Teaching. It is not a common use-case to equate ranges > in code and that is bad coding anyway. > > Hopef

Re: [Python-3000] Equality of range objects

2008-04-09 Thread Nick Coghlan
Anand Balachandran Pillai wrote: > Still this seems like a bad thing to break backward compatibility with. > However I cannot really provide a use-case apart from what Benjamin > has said -> Teaching. It is not a common use-case to equate ranges > in code and that is bad coding anyway. > > Hopeful