[Python-Dev] A panel with Guido/python-dev on scientific uses and Python 3 at Google HQ, March 2nd

2012-02-20 Thread Fernando Perez
Hi all, I wanted to point out to you folks, and invite any of you who could make it in person, to a panel discussion we'll be having on Friday March 2nd, at 3pm, during the PyData workshop that will take place at Google's headquarters in Mountain View: http://pydataworkshop.eventbrite.com The

Re: [Python-Dev] cpython (2.6): - Issue #13703: oCERT-2011-003: add -R command-line option and PYTHONHASHSEED

2012-02-20 Thread Éric Araujo
Le 21/02/2012 03:04, Benjamin Peterson a écrit : > 2012/2/20 Antoine Pitrou : >> Changing the sequence size of sys.flags can break existing code (e.g. >> tuple-unpacking). > > I told George I didn't think it was a major problem. How much code > have you seen trying to upack sys.flags? (Moreover, s

Re: [Python-Dev] cpython (2.7): use set

2012-02-20 Thread Georg Brandl
Am 21.02.2012 05:13, schrieb benjamin.peterson: > http://hg.python.org/cpython/rev/98732d20b6d1 > changeset: 75112:98732d20b6d1 > branch: 2.7 > user:Benjamin Peterson > date:Mon Feb 20 23:11:19 2012 -0500 > summary: > use set > > files: > Lib/re.py | 5 + > 1 file

Re: [Python-Dev] [Python-checkins] cpython (merge 2.6 -> 2.7): merge 2.6 with hash randomization fix

2012-02-20 Thread Gregory P. Smith
On Mon, Feb 20, 2012 at 10:19 PM, Gregory P. Smith wrote: > Look at PCbuild/pythoncore.vcproj within this commit, it looks like > you committed (or merged) a merge conflict marker in the file. > > -gps > > On Mon, Feb 20, 2012 at 6:49 PM, benjamin.peterson > wrote: >> http://hg.python.org/cpython

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Terry Reedy
On 2/20/2012 11:52 PM, Guido van Rossum wrote: On Mon, Feb 20, 2012 at 4:53 PM, Stephen J. Turnbull wrote: Steven D'Aprano writes: > Also, "Czar" is commonly used in US politics as an informal term for the top > official responsible for an area. I think here the most important connotat

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Guido van Rossum
On Mon, Feb 20, 2012 at 4:53 PM, Stephen J. Turnbull wrote: > Steven D'Aprano writes: > >  > Also, "Czar" is commonly used in US politics as an informal term for the > top >  > official responsible for an area. > > I think here the most important connotation is that in US parlance a > "czar" does

Re: [Python-Dev] accept string in a2b and base64?

2012-02-20 Thread Nick Coghlan
On Tue, Feb 21, 2012 at 11:24 AM, R. David Murray wrote: > If most people agree with Antoine I won't fight it, but it seems to me > that accepting unicode in the binascii and base64 APIs is a bad idea. I see it as essentially the same as the changes I made in urllib.urlparse to support pure ASCII

Re: [Python-Dev] cpython (2.6): - Issue #13703: oCERT-2011-003: add -R command-line option and PYTHONHASHSEED

2012-02-20 Thread Benjamin Peterson
2012/2/20 Antoine Pitrou : > On Tue, 21 Feb 2012 02:44:32 +0100 > barry.warsaw wrote: >> +   This is intended to provide protection against a denial-of-service >> caused by >> +   carefully-chosen inputs that exploit the worst case performance of a dict >> +   insertion, O(n^2) complexity.  See >

Re: [Python-Dev] cpython (2.6): - Issue #13703: oCERT-2011-003: add -R command-line option and PYTHONHASHSEED

2012-02-20 Thread Benjamin Peterson
2012/2/20 Benjamin Peterson : > I told George Sorry, Georg! -- Regards, Benjamin ___ 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/arch

Re: [Python-Dev] folding cElementTree behind ElementTree in 3.3

2012-02-20 Thread Nick Coghlan
On Tue, Feb 21, 2012 at 11:39 AM, Eli Bendersky wrote: > So the two choices here are either change the documentation or the C > implementation to actually make Element a class. The first is of course > simpler. However, someone somewhere may have written code that knowingly > forces the Python imp

Re: [Python-Dev] cpython (2.6): - Issue #13703: oCERT-2011-003: add -R command-line option and PYTHONHASHSEED

2012-02-20 Thread Antoine Pitrou
On Tue, 21 Feb 2012 02:44:32 +0100 barry.warsaw wrote: > + This is intended to provide protection against a denial-of-service caused > by > + carefully-chosen inputs that exploit the worst case performance of a dict > + insertion, O(n^2) complexity. See > + http://www.ocert.org/advisorie

Re: [Python-Dev] accept string in a2b and base64?

2012-02-20 Thread Antoine Pitrou
On Mon, 20 Feb 2012 20:24:16 -0500 "R. David Murray" wrote: > > It seems to me that part of the point of the byte/string split (and the > lack of automatic coercion) is to make the programmer be explicit about > converting between unicode and bytes. Having these functions, which > convert betwee

[Python-Dev] hash randomization in the 2.6 branch

2012-02-20 Thread Barry Warsaw
I've just committed a back port of issue 13703, the hash randomization patch, to the Python 2.6 branch. I have left the forward porting of this to Python 2.7 to Benjamin. test_json will fail with randomization enabled since there is a sort order dependency in the __init__.py doctest. I'm not goi

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Nick Coghlan
On Tue, Feb 21, 2012 at 7:09 AM, Guido van Rossum wrote: > Approved. Nick is PEP czar for PEP 3144. Thanks Nick! In that case the addition of the "ipaddress" module is approved for 3.3, with a provisional caveat on the API details. I'm doing it that way because I think those remaining details can

Re: [Python-Dev] folding cElementTree behind ElementTree in 3.3

2012-02-20 Thread Eli Bendersky
On Tue, Feb 21, 2012 at 00:51, Nick Coghlan wrote: > On Tue, Feb 21, 2012 at 1:55 AM, wrote: > >> Basically, if something is just documented as being callable without > >> subclassing or instance checks being mentioned as supported in the > >> docs, it can be implemented as either a type or an

[Python-Dev] accept string in a2b and base64?

2012-02-20 Thread R. David Murray
Two patches have been committed to 3.3 that I am very uncomfortable with. See issue 13637 and issue 13641, respectively. It seems to me that part of the point of the byte/string split (and the lack of automatic coercion) is to make the programmer be explicit about converting between unicode and by

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Stephen J. Turnbull
Steven D'Aprano writes: > Also, "Czar" is commonly used in US politics as an informal term for the top > official responsible for an area. I think here the most important connotation is that in US parlance a "czar" does not report to a committee, and with the exception of a case where Sybil is

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Steven D'Aprano
Nick Coghlan wrote: On Mon, Feb 20, 2012 at 11:55 PM, Antoine Pitrou wrote: On Mon, 20 Feb 2012 23:23:13 +1000 Nick Coghlan wrote: Does anyone object to me naming myself PEP czar for PEP 3144? “Tsar is a title used to designate certain European Slavic monarchs or supreme rulers.” Is this ou

Re: [Python-Dev] Status of PEP 397 - Python launcher for Windows

2012-02-20 Thread Mark Lawrence
On 20/02/2012 23:48, Mark Hammond wrote: On 21/02/2012 2:54 AM, Mark Lawrence wrote: The section in the docs "Using Python on Windows" would need to be updated, but would this have to happen for every current version of Python? I'm not sure what docs you are referring to here? See http://do

Re: [Python-Dev] Status of PEP 397 - Python launcher for Windows

2012-02-20 Thread Mark Hammond
On 21/02/2012 2:54 AM, Mark Lawrence wrote: On 18/02/2012 05:24, Mark Hammond wrote: ... * Write some user-oriented docs. The section in the docs "Using Python on Windows" would need to be updated, but would this have to happen for every current version of Python? I'm not sure what docs yo

Re: [Python-Dev] [Python-checkins] cpython: Issue #13641: Decoding functions in the base64 module now accept ASCII-only

2012-02-20 Thread Antoine Pitrou
On Mon, 20 Feb 2012 16:31:13 -0500 Terry Reedy wrote: > > I am a little puzzled why a constant sequence of pairs is being stored > as a mapping instead of a tuple (or list) of 2-tuples (which is compiled > more efficiently). As near as I can tell, 'tests' and similar constructs > later in the

Re: [Python-Dev] [Python-checkins] cpython: Issue #14043: Speed up importlib's _FileFinder by at least 8x, and add a new

2012-02-20 Thread Brett Cannon
On Mon, Feb 20, 2012 at 17:29, PJ Eby wrote: > On Mon, Feb 20, 2012 at 1:20 PM, Brett Cannon wrote: > >> On Sun, Feb 19, 2012 at 22:15, Nick Coghlan wrote: >> >>> However, "very cool" on adding the caching in the default importers :) >> >> >> Thanks to PJE for bringing the idea up again and Ant

Re: [Python-Dev] [Python-checkins] cpython: Issue #14043: Speed up importlib's _FileFinder by at least 8x, and add a new

2012-02-20 Thread PJ Eby
On Mon, Feb 20, 2012 at 1:20 PM, Brett Cannon wrote: > On Sun, Feb 19, 2012 at 22:15, Nick Coghlan wrote: > >> However, "very cool" on adding the caching in the default importers :) > > > Thanks to PJE for bringing the idea up again and Antoine discovering the > approach *independently* from PJE

Re: [Python-Dev] PEP 394

2012-02-20 Thread Nick Coghlan
On Tue, Feb 21, 2012 at 12:58 AM, anatoly techtonik wrote: > On Mon, Feb 20, 2012 at 4:58 PM, Nick Coghlan wrote: >> >> PEP 394 >> was at the top of my list recently > > > I've tried to edit it to be a little bit shorter (perhaps cleaner) and > commented (up to revision 2) up to Migration Notes.

Re: [Python-Dev] folding cElementTree behind ElementTree in 3.3

2012-02-20 Thread Nick Coghlan
On Tue, Feb 21, 2012 at 1:55 AM, wrote: >> Basically, if something is just documented as being callable without >> subclassing or instance checks being mentioned as supported in the >> docs, it can be implemented as either a type or an ordinary function, >> or pretty much any other kind of callab

Re: [Python-Dev] [Python-checkins] cpython: Issue #13641: Decoding functions in the base64 module now accept ASCII-only

2012-02-20 Thread Terry Reedy
On 2/20/2012 1:33 PM, antoine.pitrou wrote: http://hg.python.org/cpython/rev/c760bd844222 changeset: 75058:c760bd844222 user:Antoine Pitrou date:Mon Feb 20 19:30:23 2012 +0100 summary: Issue #13641: Decoding functions in the base64 module now accept ASCII-only unicode stri

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Guido van Rossum
Approved. Nick is PEP czar for PEP 3144. Thanks Nick! On Mon, Feb 20, 2012 at 11:13 AM, Terry Reedy wrote: > On 2/20/2012 8:23 AM, Nick Coghlan wrote: >> >> Does anyone object to me naming myself PEP czar for PEP 3144? > > > I think it great that you volunteer to be the PEP czar and hope Guido >

Re: [Python-Dev] Python in Native Client

2012-02-20 Thread Terry Reedy
On 2/20/2012 7:49 AM, anatoly techtonik wrote: People on NaCl list are asking about Python support for development of native web applications in Python. Does anybody have experience compiling Python for NaCl? https://groups.google.com/d/topic/native-client-discuss/ioY2jmw_OUQ/discussion I s

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Terry Reedy
On 2/20/2012 8:23 AM, Nick Coghlan wrote: Does anyone object to me naming myself PEP czar for PEP 3144? I think it great that you volunteer to be the PEP czar and hope Guido appoints you -- especially after your response to Antoine. Since this is a Python 3 module, let us start off with a mod

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Matt Joiner
On Mon, Feb 20, 2012 at 11:27 PM, Antoine Pitrou wrote: > IMHO, nesting without a good, consistent, systematic categorization > leads to very unpleasant results (e.g. "from urllib.request import > urlopen"). > > Historically, our stdlib has been flat and I think it should stay so, > short of redoi

Re: [Python-Dev] [Python-checkins] cpython: Issue #14043: Speed up importlib's _FileFinder by at least 8x, and add a new

2012-02-20 Thread Brett Cannon
On Sun, Feb 19, 2012 at 22:15, Nick Coghlan wrote: > However, "very cool" on adding the caching in the default importers :) Thanks to PJE for bringing the idea up again and Antoine discovering the approach *independently* from PJE and myself and actually writing the code. Now I *really* need t

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Dirkjan Ochtman
On Mon, Feb 20, 2012 at 16:27, Antoine Pitrou wrote: >> Should it be net.ipaddress instead of just ipaddress? >> >> Somewhat nested is better than fully flat. > > IMHO, nesting without a good, consistent, systematic categorization > leads to very unpleasant results (e.g. "from urllib.request impor

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Andrew Svetlov
I like 'PEP czar' On Mon, Feb 20, 2012 at 6:50 PM, Mark Lawrence wrote: > On 20/02/2012 16:28, Senthil Kumaran wrote: >> >> On Tue, Feb 21, 2012 at 12:07 AM,  wrote: >>> >>> "supreme ruler" sounds good to me. I could go for "inquisitor" instead >>> of "czar" as well... >> >> >> But that would be

Re: [Python-Dev] PEP 394

2012-02-20 Thread Andrew Svetlov
ArchLinux has used `python` as alias for `python3` while `python2` is still supported. On Mon, Feb 20, 2012 at 4:58 PM, anatoly techtonik wrote: > On Mon, Feb 20, 2012 at 4:58 PM, Nick Coghlan wrote: >> >> PEP 394 >> was at the top of my list recently > > > I've tried to edit it to be a little b

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Mark Lawrence
On 20/02/2012 16:28, Senthil Kumaran wrote: On Tue, Feb 21, 2012 at 12:07 AM, wrote: "supreme ruler" sounds good to me. I could go for "inquisitor" instead of "czar" as well... But that would be bad for developers from Spain as nobody would expect a spanish inquisition. :-) How about Big

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Senthil Kumaran
On Tue, Feb 21, 2012 at 12:07 AM, wrote: > "supreme ruler" sounds good to me. I could go for "inquisitor" instead > of "czar" as well... But that would be bad for developers from Spain as nobody would expect a spanish inquisition. :-) -- Senthil ___

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread martin
Does anyone object to me naming myself PEP czar for PEP 3144? “Tsar is a title used to designate certain European Slavic monarchs or supreme rulers.” Is this our official word? "supreme ruler" sounds good to me. I could go for "inquisitor" instead of "czar" as well... Regards, Martin ___

Re: [Python-Dev] folding cElementTree behind ElementTree in 3.3

2012-02-20 Thread martin
Basically, if something is just documented as being callable without subclassing or instance checks being mentioned as supported in the docs, it can be implemented as either a type or an ordinary function, or pretty much any other kind of callable without being deemed an API change So what would

Re: [Python-Dev] Status of PEP 397 - Python launcher for Windows

2012-02-20 Thread Mark Lawrence
On 18/02/2012 05:24, Mark Hammond wrote: I'm wondering what thoughts are on PEP 397, the Python launcher for Windows. I've been using the implementation for a number of months now and I find it incredibly useful. To my mind, the specific steps would be: * Have someone pronounce it as accepted (

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Antoine Pitrou
On Mon, 20 Feb 2012 16:20:15 +0100 Dirkjan Ochtman wrote: > On Mon, Feb 20, 2012 at 14:23, Nick Coghlan wrote: > > I don't personally think the module API needs the provisional > > disclaimer as the core functionality has been tested for years in > > ipaddr and the API changes in ipaddress are ju

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Dirkjan Ochtman
On Mon, Feb 20, 2012 at 14:23, Nick Coghlan wrote: > I don't personally think the module API needs the provisional > disclaimer as the core functionality has been tested for years in > ipaddr and the API changes in ipaddress are just cosmetic ones either > for PEP 8 conformance, or to make the API

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Nick Coghlan
On Mon, Feb 20, 2012 at 11:55 PM, Antoine Pitrou wrote: > On Mon, 20 Feb 2012 23:23:13 +1000 > Nick Coghlan wrote: >> Does anyone object to me naming myself PEP czar for PEP 3144? > > “Tsar is a title used to designate certain European Slavic monarchs or > supreme rulers.” > > Is this our officia

[Python-Dev] PEP 394

2012-02-20 Thread anatoly techtonik
On Mon, Feb 20, 2012 at 4:58 PM, Nick Coghlan wrote: > PEP 394 > was at the top of my list recently > I've tried to edit it to be a little bit shorter (perhaps cleaner) and commented (up to revision 2) up to Migration Notes. http://piratepad.net/pep-0394 The main points: 1. `python2.7` should b

Re: [Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Antoine Pitrou
On Mon, 20 Feb 2012 23:23:13 +1000 Nick Coghlan wrote: > Does anyone object to me naming myself PEP czar for PEP 3144? “Tsar is a title used to designate certain European Slavic monarchs or supreme rulers.” Is this our official word? > There's also basic-but-usable module documentation availabl

[Python-Dev] PEP czar for PEP 3144?

2012-02-20 Thread Nick Coghlan
Does anyone object to me naming myself PEP czar for PEP 3144? I've collated the objections to the original proposal on a few different occasions throughout the (long!) PEP review process, and as noted in the Background section, the latest version of the PEP [1] has addressed the key concerns that

Re: [Python-Dev] PEP 410, 3rd revision, Decimal timestamp

2012-02-20 Thread Victor Stinner
>>> We must do better than Ruby: support arbritrary precision! :-D >> >> Seriously, I do consider that a necessary requirement for the PEP (which >> the Decimal type actually meets). (...) > > (...) > Not-quite-sure-how-seriously-you-intend-supporting-yoctoseconds-ly y'rs, The point is not support

[Python-Dev] Python in Native Client

2012-02-20 Thread anatoly techtonik
Hi, People on NaCl list are asking about Python support for development of native web applications in Python. Does anybody have experience compiling Python for NaCl? 1. https://groups.google.com/d/topic/native-client-discuss/ioY2jmw_OUQ/discussion -- anatoly t. __

Re: [Python-Dev] folding cElementTree behind ElementTree in 3.3

2012-02-20 Thread Nick Coghlan
On Mon, Feb 20, 2012 at 9:43 PM, Xavier Morel wrote: > I'm not sure that's much of an issue, Element (and most of the top-level > utility "constructors") are documented as being frontend interfaces with > no specific type of their own, and indeed they are simply functions in > lxml, just as they a

Re: [Python-Dev] folding cElementTree behind ElementTree in 3.3

2012-02-20 Thread Xavier Morel
On 2012-02-20, at 12:36 , Eli Bendersky wrote: > On Mon, Feb 20, 2012 at 01:12, "Martin v. Löwis" wrote: > >>> The change of backing ElementTree by cElementTree has already been >>> implemented in the default branch (3.3) by Florent Xicluna with careful >>> review from me and others. etree has an

Re: [Python-Dev] folding cElementTree behind ElementTree in 3.3

2012-02-20 Thread Eli Bendersky
On Mon, Feb 20, 2012 at 01:12, "Martin v. Löwis" wrote: > > The change of backing ElementTree by cElementTree has already been > > implemented in the default branch (3.3) by Florent Xicluna with careful > > review from me and others. etree has an extensive (albeit a bit clumsy) > > set of tests w

Re: [Python-Dev] PEP 410, 3rd revision, Decimal timestamp

2012-02-20 Thread Steven D'Aprano
Martin v. Löwis wrote: * Ruby (1.9.3), the `Time class `_ supports picosecond (10\ :sup:`-12`) We must do better than Ruby: support arbritrary precision! :-D Seriously, I do consider that a necessary requirement for the PEP (which the Decimal type a