Re: [Python-Dev] [Python-checkins] peps: Note that ImportError will no longer be raised due to a missing __init__.py

2012-04-19 Thread Brett Cannon
It's actually an ImportWarning, not Error (or at least that's what I meant on import-sig). If the module is eventually found then there is no error. On Thu, Apr 19, 2012 at 18:56, eric.smith wrote: > http://hg.python.org/peps/rev/af61fe9a56fb > changeset: 4281:af61fe9a56fb > user:Eric V

[Python-Dev] PEP 420: Implicit Namespace Packages

2012-04-19 Thread Eric V. Smith
If you have any comments, please join the discussion over in import-sig. Eric. ___ 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%40

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Brian Curtin
On Thu, Apr 19, 2012 at 17:21, Stefan Behnel wrote: > Brian Curtin, 19.04.2012 23:19: >> On Thu, Apr 19, 2012 at 16:08, Stefan Behnel While code generation alleviates the burden of tedious languages, it's also infinitely more complex, makes debugging very difficult and adds to prere

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Stefan Behnel
Brian Curtin, 19.04.2012 23:19: > On Thu, Apr 19, 2012 at 16:08, Stefan Behnel >>> While code generation alleviates the burden of tedious languages, it's also >>> infinitely more complex, makes debugging very difficult and adds to >>> prerequisite knowledge, among other drawbacks. >> >> You can use

Re: [Python-Dev] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-19 Thread Cameron Simpson
On 19Apr2012 10:47, Stephen J. Turnbull wrote: | On Thu, Apr 19, 2012 at 8:15 AM, Victor Stinner | wrote: | > Well, I asked on IRC what I should do for these definitions because | > I'm too tired to decide what to do. [[...]] I replaced these definitions with yours. | | That was nice of you. I

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Brian Curtin
On Thu, Apr 19, 2012 at 16:08, Stefan Behnel >> While code generation alleviates the burden of tedious languages, it's also >> infinitely more complex, makes debugging very difficult and adds to >> prerequisite knowledge, among other drawbacks. > > You can use gdb for source level debugging of Cyth

Re: [Python-Dev] PEP-419: Protecting cleanup statements from interruptions

2012-04-19 Thread Victor Stinner
> PEP: 419 > Title: Protecting cleanup statements from interruptions > Version: $Revision$ > Last-Modified: $Date$ > Author: Paul Colomiets > Status: Draft > Type: Standards Track > Content-Type: text/x-rst > Created: 06-Apr-2012 > Python-Version: 3.3 Hi, I think your PEP should at least mention

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Stefan Behnel
Matt Joiner, 19.04.2012 16:13: > Personally I find the unholy product of C and Python that is Cython to be > more complex than the sum of the complexities of its parts. Is it really > wise to be learning Cython without already knowing C, Python, and the > CPython object model? The main obstacle th

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Guido van Rossum
On Thu, Apr 19, 2012 at 10:30 AM, Antoine Pitrou wrote: > On Thu, 19 Apr 2012 10:21:00 -0700 > Guido van Rossum wrote: >> On Thu, Apr 19, 2012 at 10:13 AM, Tshepang Lekhonkhobe >> wrote: >> > On Thu, Apr 19, 2012 at 18:55, Guido van Rossum wrote: >> >> On Thu, Apr 19, 2012 at 9:02 AM, Tshepang

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Antoine Pitrou
Le jeudi 19 avril 2012 à 10:40 -0700, Guido van Rossum a écrit : > >> > >> I don't think you're a core contributor, right? Even if a core > >> developer reviews the code, it requires a certain level of trust, > >> especially for complex patches. > > > > I would say trust is gained through previous

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Antoine Pitrou
On Thu, 19 Apr 2012 10:21:00 -0700 Guido van Rossum wrote: > On Thu, Apr 19, 2012 at 10:13 AM, Tshepang Lekhonkhobe > wrote: > > On Thu, Apr 19, 2012 at 18:55, Guido van Rossum wrote: > >> On Thu, Apr 19, 2012 at 9:02 AM, Tshepang Lekhonkhobe > >> wrote: > >>> On Thu, Apr 19, 2012 at 17:51, Gui

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Guido van Rossum
On Thu, Apr 19, 2012 at 10:13 AM, Tshepang Lekhonkhobe wrote: > On Thu, Apr 19, 2012 at 18:55, Guido van Rossum wrote: >> On Thu, Apr 19, 2012 at 9:02 AM, Tshepang Lekhonkhobe >> wrote: >>> On Thu, Apr 19, 2012 at 17:51, Guido van Rossum wrote: and I'm not sure we'd like to accept cod

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Tshepang Lekhonkhobe
On Thu, Apr 19, 2012 at 18:55, Guido van Rossum wrote: > On Thu, Apr 19, 2012 at 9:02 AM, Tshepang Lekhonkhobe > wrote: >> On Thu, Apr 19, 2012 at 17:51, Guido van Rossum wrote: >>> and I'm not sure we'd like to >>> accept code from convicted fellons (though I'd consider that a gray >>> area). >

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Guido van Rossum
On Thu, Apr 19, 2012 at 9:06 AM, Glyph wrote: > On Apr 19, 2012, at 11:51 AM, Guido van Rossum wrote: > > In all those cases I think there should be some core contributors who > know the real identity of the contributor. These must also know the > reason for the anonymity and agree that it's impor

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Guido van Rossum
On Thu, Apr 19, 2012 at 9:02 AM, Tshepang Lekhonkhobe wrote: > On Thu, Apr 19, 2012 at 17:51, Guido van Rossum wrote: >> and I'm not sure we'd like to >> accept code from convicted fellons (though I'd consider that a gray >> area). > > This makes me curious... why would that be a problem at all (

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Glyph
On Apr 19, 2012, at 11:51 AM, Guido van Rossum wrote: > In all those cases I think there should be some core contributors who > know the real identity of the contributor. These must also know the > reason for the anonymity and agree that it's important to maintain it. > It must also be known to th

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Tshepang Lekhonkhobe
On Thu, Apr 19, 2012 at 17:51, Guido van Rossum wrote: > and I'm not sure we'd like to > accept code from convicted fellons (though I'd consider that a gray > area). This makes me curious... why would that be a problem at all (assuming the felony is not related to the computing field)? __

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Guido van Rossum
On Thu, Apr 19, 2012 at 4:19 AM, "Martin v. Löwis" wrote:   Issue #11750: The Windows API functions scattered in the _subprocess and _multiprocessing.win32 modules now live in a single module "_winapi". Patch by sbt. >>> >>> Can we use Real Names, please? >> >> Do we have a policy a

Re: [Python-Dev] Suggested addition to PEP 8 for context managers

2012-04-19 Thread Tshepang Lekhonkhobe
was sent to Barry-only by mistake On Thu, Apr 19, 2012 at 17:20, Tshepang Lekhonkhobe wrote: > On Thu, Apr 19, 2012 at 17:15, Barry Warsaw wrote: >> If I change that phrase to "Use your own judgement" does that help? > > I would prefer "This is a matter of taste...". Much closer to original > me

Re: [Python-Dev] Suggested addition to PEP 8 for context managers

2012-04-19 Thread Éric Araujo
If I change that phrase to "Use your own judgement" does that help? It does. It may also help fight the mindset that PEP 8 is a Law. Regards ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscr

Re: [Python-Dev] Suggested addition to PEP 8 for context managers

2012-04-19 Thread Oleg Broytman
On Thu, Apr 19, 2012 at 11:15:38AM -0400, Barry Warsaw wrote: > On Apr 19, 2012, at 11:00 AM, ??ric Araujo wrote: > >> +- If operators with different priorities are used, consider adding > >> + whitespace around the operators with the lowest priority(ies). This > >> + is very much to taste; howe

Re: [Python-Dev] Suggested addition to PEP 8 for context managers

2012-04-19 Thread Barry Warsaw
On Apr 19, 2012, at 11:00 AM, Éric Araujo wrote: >Hi, > >> +- If operators with different priorities are used, consider adding >> + whitespace around the operators with the lowest priority(ies). This >> + is very much to taste; however, never use more than one space, and >> + always have the sa

Re: [Python-Dev] Suggested addition to PEP 8 for context managers

2012-04-19 Thread Chris Angelico
On Fri, Apr 20, 2012 at 1:00 AM, Éric Araujo wrote: > Hi, > >> +- If operators with different priorities are used, consider adding >> +  whitespace around the operators with the lowest priority(ies). This >> +  is very much to taste; however, never use more than one space, and >> +  always have th

Re: [Python-Dev] Suggested addition to PEP 8 for context managers

2012-04-19 Thread Éric Araujo
Hi, +- If operators with different priorities are used, consider adding + whitespace around the operators with the lowest priority(ies). This + is very much to taste; however, never use more than one space, and + always have the same amount of whitespace on both sides of a binary + operator.

Re: [Python-Dev] Suggested addition to PEP 8 for context managers

2012-04-19 Thread Barry Warsaw
On Apr 18, 2012, at 09:26 PM, Guido van Rossum wrote: >On Wed, Apr 18, 2012 at 8:14 PM, Chris Angelico wrote: >> On Thu, Apr 19, 2012 at 1:06 PM, Eli Bendersky wrote: >>> (quoting GvR) Let's change this to something more reasonable, e.g. """ If operators with different priori

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Matt Joiner
Personally I find the unholy product of C and Python that is Cython to be more complex than the sum of the complexities of its parts. Is it really wise to be learning Cython without already knowing C, Python, and the CPython object model? While code generation alleviates the burden of tedious lang

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread R. David Murray
On Thu, 19 Apr 2012 14:44:06 +0200, Antoine Pitrou wrote: > Also, while C is a low-level language, Cython is a different language > than Python when you start using its optimization features. This means > core developers have to learn that language. Hmm. On the other hand, perhaps some core deve

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Brian Curtin
On Thu, Apr 19, 2012 at 05:38, Nick Coghlan wrote: > On Thu, Apr 19, 2012 at 6:55 PM, Stefan Behnel wrote: >> What do you think? > > I think the possible use of Cython for standard library extension > modules is potentially worth looking into for the 3.4 timeframe (c.f. > the recent multiple chec

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Antoine Pitrou
On Thu, 19 Apr 2012 10:55:24 +0200 Stefan Behnel wrote: > > I noticed that there is a PEP (3154) and a GSoC proposal about improving > Pickle. Given the recent discussion on this list about using Cython for the > import module, I wonder if it wouldn't make even more sense to switch from > a C (ac

Re: [Python-Dev] cpython: Issue #11750: The Windows API functions scattered in the _subprocess and

2012-04-19 Thread Martin v. Löwis
>>> Issue #11750: The Windows API functions scattered in the _subprocess and >>> _multiprocessing.win32 modules now live in a single module "_winapi". >>> Patch by sbt. >> >> Can we use Real Names, please? > > Do we have a policy about that? sbt seems happy using a pseudonym (and > I personally

Re: [Python-Dev] Highlighting reference-stealing APIs [was Re: cpython: Fix email post-commit review comments.]

2012-04-19 Thread Martin v. Löwis
Am 19.04.2012 12:42, schrieb Sam Partington: > On 19 April 2012 02:20, Nick Coghlan wrote: >> On Thu, Apr 19, 2012 at 12:21 AM, Antoine Pitrou wrote: >>> (and here we see why reference-stealing APIs are a nuisance: because >>> you never know in advance whether a function will steal a reference or

Re: [Python-Dev] Highlighting reference-stealing APIs [was Re: cpython: Fix email post-commit review comments.]

2012-04-19 Thread Sam Partington
On 19 April 2012 02:20, Nick Coghlan wrote: > On Thu, Apr 19, 2012 at 12:21 AM, Antoine Pitrou wrote: >> (and here we see why reference-stealing APIs are a nuisance: because >> you never know in advance whether a function will steal a reference or >> not, and you have to read the docs for each an

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Nick Coghlan
On Thu, Apr 19, 2012 at 6:55 PM, Stefan Behnel wrote: > What do you think? I think the possible use of Cython for standard library extension modules is potentially worth looking into for the 3.4 timeframe (c.f. the recent multiple checkins sorting out the refcounts for the new ImportError helper

Re: [Python-Dev] Cython for cPickle?

2012-04-19 Thread Martin v. Löwis
> What do you think? I think I know what Jim Fulton thinks (as we talked about something like this a PyCon): don't. He is already sad that cPickle grew so much pickle features when it was designed as a real fast implementation. pickle speed is really important to some users, and any loss of perfor

Re: [Python-Dev] (no subject)

2012-04-19 Thread Martin v. Löwis
Am 19.04.2012 10:00, schrieb Eric Snow: > How closely is tokenize.detect_encoding() supposed to match > PyTokenizer_FindEncoding()? From what I can tell, there is a subtle > difference in their behavior that has bearing on PEP 263 handling > during import. [1] Should any difference be considered

[Python-Dev] Cython for cPickle?

2012-04-19 Thread Stefan Behnel
Hi, I noticed that there is a PEP (3154) and a GSoC proposal about improving Pickle. Given the recent discussion on this list about using Cython for the import module, I wonder if it wouldn't make even more sense to switch from a C (accelerator) implementation to Cython for _pickle. The rationale

[Python-Dev] support for encoding detection and PEP 263

2012-04-19 Thread Eric Snow
Forgot the subject (going to bed now). On Thu, Apr 19, 2012 at 2:00 AM, Eric Snow wrote: > How closely is tokenize.detect_encoding() supposed to match > PyTokenizer_FindEncoding()?  From what I can tell, there is a subtle > difference in their behavior that has bearing on PEP 263 handling > durin

[Python-Dev] (no subject)

2012-04-19 Thread Eric Snow
How closely is tokenize.detect_encoding() supposed to match PyTokenizer_FindEncoding()? From what I can tell, there is a subtle difference in their behavior that has bearing on PEP 263 handling during import. [1] Should any difference be considered a bug, or should I work around it? Thanks. -er