Re: [Python-Dev] ctypes compatibility with 2.3

2016-05-11 Thread Brett Cannon
On Wed, 11 May 2016 at 09:28 Brett Cannon wrote: > On Wed, 11 May 2016 at 09:07 Thomas Heller wrote: > >> Am 11.05.2016 um 18:04 schrieb Brett Cannon: >> > >> > >> > On Wed, 11 May 2016 at 04:35 Thomas Heller > > <mailto:thel...@ctypes.org>&g

Re: [Python-Dev] file system path protocol PEP

2016-05-12 Thread Brett Cannon
On Thu, 12 May 2016 at 09:25 Guido van Rossum wrote: > I am glad this is finally happening. There's quite a bit of noise in the > thread which I have to ignore. > Don't worry, I'm not ignoring it on your behalf. :) > The two issues that I want to respond to are speed and whether os.fspath() >

Re: [Python-Dev] file system path protocol PEP

2016-05-12 Thread Brett Cannon
On Thu, 12 May 2016 at 11:36 Guido van Rossum wrote: > On Thu, May 12, 2016 at 10:18 AM, Brett Cannon wrote: > >> On Thu, 12 May 2016 at 09:25 Guido van Rossum wrote: >> > def fspath(p: Union[str, bytes, PathLike]) -> Union[str, bytes]: >>>

Re: [Python-Dev] file system path protocol PEP

2016-05-12 Thread Brett Cannon
On Thu, 12 May 2016 at 12:03 Guido van Rossum wrote: > On Thu, May 12, 2016 at 11:51 AM, Brett Cannon wrote: > >> >> Anyway, with your strong preference of how to tweak os.fspath() what >> specifically would you like to see discussed at this point? >> > >

[Python-Dev] File system path PEP, part 2

2016-05-12 Thread Brett Cannon
Bunch of things added to the Rejected Ideas section -- PEP: NNN Title: Adding a file system path protocol Version: $Revision$ Last-Modified: $Date$ Author: Brett Cannon Status: Draft Type: Standards Track Content-Type: text/x-rst Created: 11-May-2016 Post-History: 11-May-2016,

Re: [Python-Dev] file system path protocol PEP

2016-05-12 Thread Brett Cannon
On Thu, 12 May 2016 at 14:04 Sjoerd Job Postmus wrote: > > > > On 12 May 2016, at 21:30, Ethan Furman wrote: > > > > If you need bytes support for your paths, there's at least one [1] that > has that support. > > So if I would need bytes support, I should submit a pull request to > which replac

Re: [Python-Dev] PEP 515: Underscores in Numeric Literals (revision 3)

2016-05-12 Thread Brett Cannon
van Rossum wrote: >> > If the authors are happy I'll accept it right away. >> > >> > (I vaguely recall there's another PEP that's ready for pronouncement -- >> but >> > which one?) >> > >> > On Wed, May 11, 2016 at 9:34 A

Re: [Python-Dev] file system path protocol PEP

2016-05-13 Thread Brett Cannon
On Fri, 13 May 2016 at 02:25 Sven R. Kunze wrote: > On 13.05.2016 10:36, Koos Zevenhoven wrote: > > This has just been discussed very recently in this thread (and earlier > > too). > > Could you point me to that? It seems I missed that part. I only found > posts related to performance degradation

Re: [Python-Dev] File system path PEP, part 2

2016-05-13 Thread Brett Cannon
On Fri, 13 May 2016 at 04:00 Steven D'Aprano wrote: > On Thu, May 12, 2016 at 08:53:12PM +0000, Brett Cannon wrote: > > > Second draft that takes Guido's comments into consideration. The biggest > > change is os.fspath() now returns whatever path.__fspath__() return

Re: [Python-Dev] File system path PEP, part 2

2016-05-13 Thread Brett Cannon
On Fri, 13 May 2016 at 10:53 Steven D'Aprano wrote: > On Fri, May 13, 2016 at 03:43:29PM +0000, Brett Cannon wrote: > > On Fri, 13 May 2016 at 04:00 Steven D'Aprano > wrote: > > [...] > > > - but os.fspath() will only return str; > > > - and os.fs

[Python-Dev] File system path PEP, 3rd draft

2016-05-13 Thread Brett Cannon
t; in the glossary (for Steven) 4. Various more things added to Rejected Ideas 5. Added Koos as a co-author (for Koos :) -- PEP: NNN Title: Adding a file system path protocol Version: $Revision$ Last-Modified: $Date$ Author: Brett Cannon , Koos Zevenhoven Status: Draft Type: Stan

Re: [Python-Dev] File system path PEP, 3rd draft

2016-05-13 Thread Brett Cannon
On Fri, 13 May 2016 at 12:08 Barry Warsaw wrote: > On May 13, 2016, at 06:37 PM, Brett Cannon wrote: > > >PEP: NNN > >Title: Adding a file system path protocol > >Version: $Revision$ > >Last-Modified: $Date$ > >Author: Brett Cannon , > >

Re: [Python-Dev] Adding Type[C] to PEP 484

2016-05-13 Thread Brett Cannon
On Fri, 13 May 2016 at 12:38 Guido van Rossum wrote: > I've got another proposed update to PEP 484 ready. There was previously > some discussion on python-ideas (Bcc'ed for closure) and quite a bit on the > typing issue tracker: https://github.com/python/typing/issues/107 > > I've worked all that

[Python-Dev] quick GitHub transition update (was: File system path PEP, 3rd draft)

2016-05-13 Thread Brett Cannon
out "nice to have", only about "without this I flat-out won't contribute to Python on GitHub"). > On Fri, May 13, 2016 at 12:24 PM, Brett Cannon wrote: > >> >> >> On Fri, 13 May 2016 at 12:08 Barry Warsaw wrote: >> >>> On M

Re: [Python-Dev] File system path PEP, 3rd draft

2016-05-13 Thread Brett Cannon
On Fri, 13 May 2016 at 14:30 Philip Jenvey wrote: > > On May 13, 2016, at 11:37 AM, Brett Cannon wrote: > > Biggest changes since the second draft: > >1. Resolve __fspath__() from the type, not the instance (for Guido) > > > if (PyObject_HasAttrString

Re: [Python-Dev] File system path PEP, 3rd draft

2016-05-16 Thread Brett Cannon
assign a BDFL delegate? On Fri, 13 May 2016 at 11:37 Brett Cannon wrote: > Biggest changes since the second draft: > >1. Resolve __fspath__() from the type, not the instance (for Guido) >2. Updated the TypeError messages to say "os.PathLike object" instead >of &quo

Re: [Python-Dev] File system path PEP, 3rd draft

2016-05-16 Thread Brett Cannon
On Mon, 16 May 2016 at 13:12 Guido van Rossum wrote: > Once you assign yourself a PEP number I'll do one more pass and then I > expect to accept it -- the draft looks good to me! > Done: https://hg.python.org/peps/rev/b41cb718054a > > On Mon, May 16, 2016 at 1:00 PM,

Re: [Python-Dev] File system path PEP, 3rd draft

2016-05-16 Thread Brett Cannon
27;t get updated in 3.4, 3.5, and 3.6 before PyCon it will be the first thing I do at the sprints so that it isn't an issue for the 3.5.2 release. -Brett > > > > On Mon, May 16, 2016 at 1:26 PM, Brett Cannon wrote: > >> >> >> On Mon, 16 May 2016 at 13:12 Guid

Re: [Python-Dev] File system path PEP, 3rd draft

2016-05-16 Thread Brett Cannon
On Mon, May 16, 2016, 19:02 Ethan Furman wrote: > On 05/16/2016 02:32 PM, Brett Cannon wrote: > > > PEP 519 is now marked as accepted! Two PEPs accepted in one day (Nick > > approved 518 earlier)! > > Excellent! :) > > > If pathlib doesn't get updated in

Re: [Python-Dev] Python2.7.11+ as in Debian testing and Ubuntu 16.04 LTS crashes with segfault

2016-05-17 Thread Brett Cannon
On Tue, 17 May 2016 at 08:15 Dr. Ján Jockusch wrote: > Hello Python Developers, > > I would like to draw your attention to a segmentation fault bug which > concerns the packaged versions of Python 2.7.11 as seen in Ubuntu's > latest 16.04 release and in Debian testing. > > > I have reported this

[Python-Dev] Why does PEP 7/8 explicitly suggest 2 spaces after a period?

2016-05-20 Thread Brett Cannon
Is there a specific reason for calling out two spaces in comments after a period(I realize it's probably for consistency, but I sure don't ever think about this when I write comment)? Otherwise who actually still writes using two spaces after punctuation? :)

[Python-Dev] Removing the provisional label from pathlib

2016-05-20 Thread Brett Cannon
Three questions: 1. Should pathlib gain __fspath__() all the way back to 3.4? 2. Should pathlib's constructor support __fspath__() all the way back to 3.4? (separate question as os.fspath() will only be in 3.6; and if we backport I'm not looking forward to making Typeshed happy w/o os.

Re: [Python-Dev] Why does PEP 7/8 explicitly suggest 2 spaces after a period?

2016-05-20 Thread Brett Cannon
wo space specification to one-space, just why specify at all to that granularity of formatting? -Brett > > On Fri, May 20, 2016 at 9:40 AM, Facundo Batista > wrote: > > On Fri, May 20, 2016 at 1:27 PM, Brett Cannon wrote: > > > >> Is there a specific rea

Re: [Python-Dev] Removing the provisional label from pathlib

2016-05-20 Thread Brett Cannon
__fspath__. > WFM. I'll let 3.4 and 3.5 just stay as they are and make all PEP 519 changes a 3.6 thing. I'll update the implementation task list shortly. -Brett > > On Fri, May 20, 2016 at 9:43 AM, Brett Cannon wrote: > > Three questions: > > > > Should pathl

Re: [Python-Dev] Removing the provisional label from pathlib

2016-05-23 Thread Brett Cannon
On Mon, May 23, 2016, 09:55 Chris Barker wrote: > On Fri, May 20, 2016 at 11:42 AM, Brett Cannon wrote: > >> >> WFM. I'll let 3.4 and 3.5 just stay as they are and make all PEP 519 >> changes a 3.6 thing. >> > > I'd like to see it in 3.5 i

Re: [Python-Dev] devinabox has moved to GitHub

2016-05-25 Thread Brett Cannon
ne, but I don't know if any of those tools really promote downloading older versions such that one has to worry about it. > > On Sun, May 8, 2016 at 4:41 PM, Brett Cannon wrote: > > https://github.com/python/devinabox > > > > The single issue for devinabox has moved to it

Re: [Python-Dev] [Python-checkins] peps: Short subsection on annotating coroutines (Ivan L, #225).

2016-05-25 Thread Brett Cannon
On Tue, 24 May 2016 at 12:20 guido.van.rossum wrote: > https://hg.python.org/peps/rev/50c3f5aefbb7 > changeset: 6341:50c3f5aefbb7 > user:Guido van Rossum > date:Tue May 24 12:18:54 2016 -0700 > summary: > Short subsection on annotating coroutines (Ivan L, #225). > > files: >

Re: [Python-Dev] runtime dlls on Windows

2016-05-26 Thread Brett Cannon
On Thu, 26 May 2016 at 09:44 Chris Barker wrote: > [SNIP] > Thanks Steve. Will you be at PyCon? if Nathaniel and I look at this > during the sprints, maybe you could coach us a bit. > Steve will be at PyCon but I don't think he will be around for the sprints as he has to catch a flight out for

Re: [Python-Dev] Adding NewType() to PEP 484

2016-05-27 Thread Brett Cannon
Patches to Python's stdlib should go through bugs.python.org so it isn't lost in email. On Fri, May 27, 2016, 12:00 Ivan Levkivskyi wrote: > Hi, > > It has been proposed to enhance the typing module with a NewType function > that allows to define simple unique types with almost zero runtime > ov

Re: [Python-Dev] New hash algorithms: SHA3, SHAKE, BLAKE2, truncated SHA512

2016-05-28 Thread Brett Cannon
On Sat, May 28, 2016, 13:58 Christian Heimes wrote: > On 2016-05-27 03:54, M.-A. Lemburg wrote: > > On 27.05.2016 06:54, Raymond Hettinger wrote: > >> > >>> On May 25, 2016, at 3:29 AM, Christian Heimes > wrote: > >>> > >>> I have three hashing-related patches for Python 3.6 that are waiting > f

Re: [Python-Dev] embedding - PyImport_AppendInittab() after Py_Initialize()

2016-05-30 Thread Brett Cannon
On Fri, 27 May 2016 at 07:50 Vitaly Murashev wrote: > Could anyone please clarify whether it is correct in python3.5 to call > PyImport_AppendInittab() after Py_Initialize() > It should be called before as PyImport_AppendInittab() is shorthand for PyImport_ExtendInittab() and it says to call pri

[Python-Dev] frame evaluation API PEP

2016-06-03 Thread Brett Cannon
ion: $Revision$ Last-Modified: $Date$ Author: Brett Cannon , Dino Viehland Status: Draft Type: Standards Track Content-Type: text/x-rst Created: 16-May-2016 Post-History: 16-May-2016 03-Jun-2016 Abstract This PEP proposes to expand CPython's C API [#c-api]_ to allow

Re: [Python-Dev] Improving the bytecode

2016-06-04 Thread Brett Cannon
It's not on the list but I'm hoping to convince Dino to work on END_FINALLY to be a bit more sane. On Sat, Jun 4, 2016, 01:17 Serhiy Storchaka wrote: > Following the converting 8-bit bytecode to 16-bit bytecode (wordcode), > there are other issues for improving the bytecode. > > 1. http://bugs.p

[Python-Dev] Current start-up times

2013-10-18 Thread Brett Cannon
tl;dr: 2.7 -> 3.3 = 1.92x slower 2.7 -> 3.4 = 1.36x slower 3.3 -> 3.4 = 1.40x faster IOW the work people have been putting in to speed up interpreter startup are definitely paying off. > ./perf.py -b normal_startup,startup_nosite ../cpython/py3.3/python.exe ../cpython/default/python.exe Running

Re: [Python-Dev] Daily reference leaks (30f33e6a04c1): sum=975756

2013-10-18 Thread Brett Cannon
On Fri, Oct 18, 2013 at 1:34 PM, Zachary Ware wrote: > On Fri, Oct 18, 2013 at 12:30 PM, Antoine Pitrou > wrote: > > > > Is anyone looking into those leaks? > > I suspect they might have to do with Serhiy's latest re changes in > > add40e9f7cbe. > > (just a barely educated guess, though) > > I ha

Re: [Python-Dev] Daily reference leaks (30f33e6a04c1): sum=975756

2013-10-18 Thread Brett Cannon
On Fri, Oct 18, 2013 at 1:51 PM, Brett Cannon wrote: > > > On Fri, Oct 18, 2013 at 1:34 PM, Zachary Ware < > zachary.ware+py...@gmail.com> wrote: > >> On Fri, Oct 18, 2013 at 12:30 PM, Antoine Pitrou >> wrote: >> > >> > Is anyone looking int

Re: [Python-Dev] Daily reference leaks (30f33e6a04c1): sum=975756

2013-10-18 Thread Brett Cannon
On Fri, Oct 18, 2013 at 1:53 PM, Brett Cannon wrote: > > > > On Fri, Oct 18, 2013 at 1:51 PM, Brett Cannon wrote: > >> >> >> On Fri, Oct 18, 2013 at 1:34 PM, Zachary Ware < >> zachary.ware+py...@gmail.com> wrote: >> >>> On Fri, Oct 18,

Re: [Python-Dev] [Python-checkins] cpython: Issue #18810: Be optimistic with stat calls when seeing if a directory

2013-10-19 Thread Brett Cannon
On Fri, Oct 18, 2013 at 9:06 PM, Nick Coghlan wrote: > > On 19 Oct 2013 03:24, "brett.cannon" wrote: > > > > http://hg.python.org/cpython/rev/11f2f4af1979 > > changeset: 86444:11f2f4af1979 > > user:Brett Cannon > > date:Fri Oct 1

Re: [Python-Dev] [Python-checkins] cpython: Issue #18416: Fix various os calls in importlib.machinery.FileFinder

2013-10-19 Thread Brett Cannon
On Fri, Oct 18, 2013 at 8:55 PM, Nick Coghlan wrote: > > On 19 Oct 2013 02:01, "brett.cannon" wrote: > > > > http://hg.python.org/cpython/rev/33844153cd02 > > changeset: 86438:33844153cd02 > > user:Brett Cannon > > date:Fri Oct 1

Re: [Python-Dev] PEP 454 (tracemalloc): new minimalist version

2013-10-19 Thread Brett Cannon
On Sat, Oct 19, 2013 at 10:00 AM, Charles-François Natali < cf.nat...@gmail.com> wrote: > 2013/10/19 Nick Coghlan : > > > > Speaking of which... Charles-François, would you be willing to act as > > BDFL-Delegate for this PEP? This will be a very useful new analysis tool, > > and between yourself a

Re: [Python-Dev] PyCon US 2014

2013-10-22 Thread Brett Cannon
On Fri, Oct 11, 2013 at 11:23 AM, Michael Foord wrote: > > On 10 Oct 2013, at 01:53, Eric Snow wrote: > > > Registration is now open for PyCon US 2014. Are there any plans yet > > for the language summit? Just the day (e.g. Thursday April 10) will > > suffice. Then we can make arrangements app

Re: [Python-Dev] [Python-checkins] cpython: Close #19379: Lazily import linecache in the warnings module, to make startup

2013-10-24 Thread Brett Cannon
The diff doesn't show an addition to BENCH_GROUPS. Maybe apps? On Thu, Oct 24, 2013 at 4:24 PM, antoine.pitrou wrote: > http://hg.python.org/cpython/rev/8939c0196990 > changeset: 86603:8939c0196990 > user:Antoine Pitrou > date:Thu Oct 24 22:23:42 2013 +0200 > summary: > Clos

Re: [Python-Dev] PEP 451 update

2013-10-25 Thread Brett Cannon
On Thu, Oct 24, 2013 at 2:05 AM, Eric Snow wrote: > I've had some offline discussion with Brett and Nick about PEP 451 > which has led to some meaningful clarifications in the PEP. In the > interest of pulling further discussions back onto this > (archived/public) list, here's an update of what w

Re: [Python-Dev] PEP 451 update

2013-10-25 Thread Brett Cannon
On Fri, Oct 25, 2013 at 11:44 AM, Eric Snow wrote: > On Fri, Oct 25, 2013 at 9:40 AM, Brett Cannon wrote: > > After reading Eric's doc patch, I realized there is one change I want to > > make to the current semantics and that's not to backfill __package__ when > &g

Re: [Python-Dev] PEP 451 update

2013-10-25 Thread Brett Cannon
On Fri, Oct 25, 2013 at 12:24 PM, PJ Eby wrote: > I've not really had time to review this PEP yet, but from skimming > discussion to date, the only thing I'm still worried about is whether > this will break lazy import schemes that use a module subclass that > hooks __getattribute__ and calls rel

Re: [Python-Dev] PEP 451 update

2013-10-25 Thread Brett Cannon
On Fri, Oct 25, 2013 at 2:10 PM, PJ Eby wrote: > On Fri, Oct 25, 2013 at 1:15 PM, Brett Cannon wrote: > > > > On Fri, Oct 25, 2013 at 12:24 PM, PJ Eby wrote: > >> At least through all 2.x, reload() just uses module.__name__ to > >> restart the module find-and-

Re: [Python-Dev] PEP 451 update

2013-11-01 Thread Brett Cannon
On Thu, Oct 31, 2013 at 6:10 PM, Nick Coghlan wrote: > > On 1 Nov 2013 01:37, "PJ Eby" wrote: > . ;-) > > > > I also suspect, that if properly spelled out, those use cases are > > going to boil down to: > > > > 1. Throwing errors if you have an existing module object you can't > > load into, an

Re: [Python-Dev] PEP 451 update

2013-11-01 Thread Brett Cannon
On Fri, Nov 1, 2013 at 1:52 PM, Eric Snow wrote: > On Fri, Nov 1, 2013 at 7:35 AM, Brett Cannon wrote: > > On Thu, Oct 31, 2013 at 6:10 PM, Nick Coghlan > wrote: > >> At the time when find_spec runs, sys.modules hasn't been touched yet, so > >> the old m

Re: [Python-Dev] PEP 451 update

2013-11-02 Thread Brett Cannon
On Sat, Nov 2, 2013 at 5:46 AM, Nick Coghlan wrote: > On 2 November 2013 08:44, Eric Snow wrote: > > On Fri, Nov 1, 2013 at 11:59 AM, Brett Cannon wrote: > >> Thanks for the clarification. It all SGTM. > > > > I've updated the PEP and the reference implementa

Re: [Python-Dev] A small patch.

2013-11-06 Thread Brett Cannon
Please put all patches on bugs.python.org, else we will lose track of the change. On Wed, Nov 6, 2013 at 2:17 PM, Sreenivas Reddy T < thatiparthysreeni...@gmail.com> wrote: > diff -r bec6df56c053 Lib/datetime.py > --- a/Lib/datetime.pyTue Nov 05 22:01:46 2013 +0200 > +++ b/Lib/datetime.py

Re: [Python-Dev] Avoid formatting an error message on attribute error

2013-11-07 Thread Brett Cannon
On Thu, Nov 7, 2013 at 7:41 AM, Nick Coghlan wrote: > > On 7 Nov 2013 21:34, "Victor Stinner" wrote: > > > > 2013/11/7 Steven D'Aprano : > > > My initial instinct here was to say that sounded like premature > > > optimization, but to my surprise the overhead of generating the error > > > message

Re: [Python-Dev] Avoid formatting an error message on attribute error

2013-11-07 Thread Brett Cannon
On Thu, Nov 7, 2013 at 2:20 PM, Eric Snow wrote: > On Thu, Nov 7, 2013 at 11:44 AM, Brett Cannon wrote: > > Lazy message creation through > > __str__ does leave the message out of `args`, though. > > If that's an issue you could make args a (settable) property that >

Re: [Python-Dev] PEP 451 (ModuleSpec) is accepted

2013-11-08 Thread Brett Cannon
oader mechanism to the stdlib. On Fri, Nov 8, 2013 at 2:49 PM, Eric Snow wrote: > I'm pleased to announce that Brett Cannon and Nick Coghlan (the > co-BDFL-delegates) have accepted PEP 451 for inclusion in Python 3.4. > Both of them have contributed substantially to the discussions of

Re: [Python-Dev] The pysandbox project is broken

2013-11-13 Thread Brett Cannon
On Wed, Nov 13, 2013 at 6:30 AM, Facundo Batista wrote: > On Wed, Nov 13, 2013 at 4:37 AM, Maciej Fijalkowski > wrote: > > >> Do you think it would be productive to create an independent Python > >> compiler, designed with sandboxing in mind from the beginning? > > > > PyPy sandbox does work FYI

Re: [Python-Dev] The pysandbox project is broken

2013-11-13 Thread Brett Cannon
On Wed, Nov 13, 2013 at 1:05 PM, Eli Bendersky wrote: > > > > On Wed, Nov 13, 2013 at 6:58 AM, Brett Cannon wrote: > >> >> >> >> On Wed, Nov 13, 2013 at 6:30 AM, Facundo Batista < >> facundobati...@gmail.com> wrote: >> >>&

Re: [Python-Dev] unicode Exception messages in py2.7

2013-11-15 Thread Brett Cannon
On Fri, Nov 15, 2013 at 12:41 PM, Chris Barker wrote: > On Fri, Nov 15, 2013 at 9:21 AM, Armin Rigo wrote: > > > I figured that even using the traceback.py module and getting > > "Exception: \u1234\u1235\u5321" is rather useless if you tried to > > raise an exception with a message in Thai. > > y

Re: [Python-Dev] Mixed up core/module source file locations in CPython

2013-11-16 Thread Brett Cannon
On Sat, Nov 16, 2013 at 1:40 PM, Eric Snow wrote: > If you look at the Python and Modules directories in the cpython repo, > you'll find modules in Python/ and core files (like python.c and > main.c) in Modules/. (It's like parking on a driveway and driving on > a parkway. ) It's not that big a

Re: [Python-Dev] Mixed up core/module source file locations in CPython

2013-11-17 Thread Brett Cannon
On Nov 17, 2013 8:58 AM, "Eli Bendersky" wrote: > > > > > On Sat, Nov 16, 2013 at 3:44 PM, Brett Cannon wrote: >> >> >> >> >> On Sat, Nov 16, 2013 at 1:40 PM, Eric Snow wrote: >>> >>> If you look at the Python and Module

Re: [Python-Dev] unicode Exception messages in py2.7

2013-11-18 Thread Brett Cannon
On Mon, Nov 18, 2013 at 12:15 PM, Chris Barker wrote: > Folks, > > It seems changing anything about how Exception messages are handles is off > the table for 2.7, and a non-issue in 3.* > > Is it worth opening an issue on this, just so we can close it as won't > fix? Or is this thread documentatio

Re: [Python-Dev] PEP 428 - pathlib - ready for approval

2013-11-19 Thread Brett Cannon
On Tue, Nov 19, 2013 at 4:04 PM, Antoine Pitrou wrote: > > Hello, > > Guido has told me that he was ready to approve PEP 428 (pathlib) in its > latest amended form. Here is the last call for any comments or > arguments against approval, before Guido marks the PEP accepted (or > changes his mind

Re: [Python-Dev] PEP 428 - pathlib - ready for approval

2013-11-21 Thread Brett Cannon
On Wed, Nov 20, 2013 at 5:41 PM, Mark Lawrence wrote: > On 20/11/2013 22:01, Antoine Pitrou wrote: > >> >> pathlib imports many modules at startup, so for scripts for which >> startup time is critical using os.path may still be the best option. >> >> > Will there be or is there a note to this effe

Re: [Python-Dev] PEP 0404 and VS 2010

2013-11-21 Thread Brett Cannon
On Thu, Nov 21, 2013 at 4:09 PM, Greg Ewing wrote: > Concerning the version number, I thought the intention of > PEP 404 was simply to say that the PSF would not be releasing > anything called Python 2.8, not to forbid anyone *else* > from doing so. > > Or am I wrong about that? > Well, it's esse

Re: [Python-Dev] PEP 0404 and VS 2010

2013-11-21 Thread Brett Cannon
On Thu, Nov 21, 2013 at 10:31 AM, Christian Heimes wrote: > Am 21.11.2013 16:12, schrieb Barry Warsaw: > > On Nov 21, 2013, at 02:16 PM, Kristján Valur Jónsson wrote: > > > >> Oh, this is the misunderstanding. No one is trying to get permission > for > >> "CPython 2.8", only "Stackless Python 2.8

Re: [Python-Dev] Assign(expr* targets, expr value) - why targetS?

2013-11-22 Thread Brett Cannon
On Fri, Nov 22, 2013 at 7:29 AM, Benjamin Peterson wrote: > 2013/11/22 anatoly techtonik : > > On Fri, Nov 15, 2013 at 5:43 PM, Benjamin Peterson > wrote: > >> 2013/11/15 anatoly techtonik : > >>> On Tue, Nov 12, 2013 at 5:08 PM, Benjamin Peterson < > benja...@python.org> wrote: > 2013/11/12

Re: [Python-Dev] PEP 451 (ModuleSpec) has landed

2013-11-22 Thread Brett Cannon
On Fri, Nov 22, 2013 at 11:37 AM, Eric Snow wrote: > On Fri, Nov 22, 2013 at 9:36 AM, Eric Snow > wrote: > > The bulk of PEP 451 (all but the "fluffy" parts as Brett called them > > ) is now committed to default. > > I'm looking into buildbot failures (on Windows of course). .. which have now b

Re: [Python-Dev] PEP process entry point and ill fated initiatives

2013-11-29 Thread Brett Cannon
On Fri, Nov 29, 2013 at 10:25 AM, Kristján Valur Jónsson < krist...@ccpgames.com> wrote: > > > > -Original Message- > > From: Python-Dev [mailto:python-dev- > > bounces+kristjan=ccpgames@python.org] On Behalf Of Antoine Pitrou > > Sent: 29. nóvember 2013 14:58 > > To: python-dev@python

[Python-Dev] Python 3 is five years old

2013-12-04 Thread Brett Cannon
On 2008-12-03, Python 3.0.0 was released by Barry. I was actually on IRC the night when it happened, with Guido leaving his office across the hall from mine. We gave each other a high-five and then we both went home. Not exactly a party, but I know I at least breathed a sigh of relief that Python 3

Re: [Python-Dev] One-line abstractmethod function?

2013-12-05 Thread Brett Cannon
On Thu, Dec 5, 2013 at 2:22 PM, Ethan Furman wrote: > On 12/05/2013 10:56 AM, Alexander Belopolsky wrote: > >> On Thu, Dec 5, 2013 at 1:24 PM, Guido van Rossum wrote: >> >>> >>> How would you get the docstrings in? [...] >>> >> >> One way to reduce the amount of boilerplate code is to make abstra

[Python-Dev] How do we feel about using pragmas and __attribute__ in C code?

2013-12-13 Thread Brett Cannon
http://bugs.python.org/issue12837 deals with the single compiler warning left on OS X: a tautalogical compare in socketmodule.c that is valid under POSIX. I have a solution that uses pragmas to turn off tautological compare warnings for the single 'if' statement that triggers it. But there are very

Re: [Python-Dev] cffi in stdlib

2013-12-17 Thread Brett Cannon
Maybe someone from PyPy should bring this up as an official topic at the language summit to figure out the blockers (again). Or it can join regex on the list of "module discussed for addition at the language summit but never quite pushed to commitment". =) On Tue, Dec 17, 2013 at 11:43 AM, Stefan

Re: [Python-Dev] Python 2.7 root buildbot showing errors

2014-01-06 Thread Brett Cannon
On Mon, Jan 6, 2014 at 2:09 AM, Chris Angelico wrote: > The first build my new root buildbot did showed errors in the 2.7 test > suite, but I thought little of it as quite a few other 2.7 buildbots > are showing red, too. But it seems they're showing different errors, > so there might be somethin

Re: [Python-Dev] RFC: PEP 460: Add bytes % args and bytes.format(args) to Python 3.5

2014-01-06 Thread Brett Cannon
On Mon, Jan 6, 2014 at 8:59 AM, Antoine Pitrou wrote: > On Tue, 7 Jan 2014 00:54:17 +1100 > Chris Angelico wrote: > > On Tue, Jan 7, 2014 at 12:44 AM, Antoine Pitrou > wrote: > > > BTW, there's a subtlety here: ``%s`` currently means "insert the result > > > of calling __str__", but bytes forma

Re: [Python-Dev] RFC: PEP 460: Add bytes % args and bytes.format(args) to Python 3.5

2014-01-06 Thread Brett Cannon
On Mon, Jan 6, 2014 at 8:44 AM, Antoine Pitrou wrote: > > Hi, > > On Mon, 6 Jan 2014 14:24:50 +0100 > Victor Stinner wrote: > > > > The PEP is a draft with open questions. First, I'm not sure that both > > bytes%args and bytes.format(args) are needed. The implementation of > > .format() is more

Re: [Python-Dev] RFC: PEP 460: Add bytes % args and bytes.format(args) to Python 3.5

2014-01-06 Thread Brett Cannon
On Mon, Jan 6, 2014 at 9:45 AM, Nick Coghlan wrote: > > On 6 Jan 2014 22:15, "Brett Cannon" wrote: > > > > > > > > > > On Mon, Jan 6, 2014 at 8:59 AM, Antoine Pitrou > wrote: > >> > >> On Tue, 7 Jan 2014 00:54:17 +1100 > >

Re: [Python-Dev] Proposed: The Great Argument Clinic Conversion Derby

2014-01-06 Thread Brett Cannon
On Mon, Jan 6, 2014 at 3:40 PM, Skip Montanaro wrote: > On Mon, Jan 6, 2014 at 2:17 PM, Antoine Pitrou > wrote: > >> I agree with Serhiy, but that is probably known at this point. :) > > > > I agree with Serhiy and you too. Clinic's current output makes C files > > more tedious to read, and I'm

Re: [Python-Dev] Changing Clinic's output

2014-01-07 Thread Brett Cannon
On Tue, Jan 7, 2014 at 4:44 PM, Stefan Krah wrote: > Antoine Pitrou wrote: > > Several solutions have been proposed: > > - move all generated code to separate C files, which would then be > > #included'd into the main module file > > +1 for the reasons that Serhiy has listed. Additionally, if

Re: [Python-Dev] Changing Clinic's output

2014-01-07 Thread Brett Cannon
On Tue, Jan 7, 2014 at 6:24 PM, Larry Hastings wrote: > On 01/07/2014 12:46 PM, Mark Lawrence wrote: > > > Maybe overkill but why not follow 3 with 2 at the end of the file, the > marker to be a very clear /* Generated by Argument Clinic - DO NOT EDIT > BELOW THIS LINE */ or whatever wording is

Re: [Python-Dev] Changing Clinic's output

2014-01-08 Thread Brett Cannon
On Tue, Jan 7, 2014 at 7:07 PM, Larry Hastings wrote: > > > On 01/07/2014 03:38 PM, Brett Cannon wrote: > > On Tue, Jan 7, 2014 at 6:24 PM, Larry Hastings wrote: > >> For what it's worth, if we use the "accumulator" approach I propose >> that the

Re: [Python-Dev] Changing Clinic's output

2014-01-08 Thread Brett Cannon
On Wed, Jan 8, 2014 at 10:46 AM, Larry Hastings wrote: > > > On 01/08/2014 07:33 AM, Brett Cannon wrote: > > So let's make this idea concrete to focus a possible discussion. Using the > example from the Clinic HOWTO and converting to how I see it working: > [...]

Re: [Python-Dev] Python3 "complexity"

2014-01-09 Thread Brett Cannon
On Thu, Jan 9, 2014 at 5:00 PM, Chris Barker wrote: > On Thu, Jan 9, 2014 at 1:45 PM, Antoine Pitrou wrote: > >> > latin-1 guaranteed to work with any binary data, and round-trip >> accurately? >> >> Yes, it is. >> >> > and will surrogateescape work for arbitrary binary data? >> >> Yes, it will.

Re: [Python-Dev] test.support.check_warnings

2014-01-11 Thread Brett Cannon
On Sat, Jan 11, 2014 at 3:45 PM, Ethan Furman wrote: > The docs say this [1]: > == > test.support.check_warnings(*filters, quiet=True) > > A convenience wrapper for warnings.catch_warnings() that makes it > easier to test that a warning

Re: [Python-Dev] byteformat() proposal: please critique

2014-01-11 Thread Brett Cannon
On Sat, Jan 11, 2014 at 8:20 PM, Terry Reedy wrote: > The following function interpolates bytes, bytearrays, and formatted > strings, the latter two auto-converted to bytes, into a bytes (or > auto-converted bytearray) format. This function automates much of what some > people have recommended fo

[Python-Dev] Trying to focus the whole bytes/str formatting discussion

2014-01-12 Thread Brett Cannon
I don't know about the rest of you but I feel like the discussion is heading off the rails (if it hasn't already jumped the tracks). Let's try to bring this back around to something actionable which people can focus their energy on as the amount of developer time spent arguing could have led to sev

Re: [Python-Dev] PEP 460 reboot

2014-01-13 Thread Brett Cannon
On Mon, Jan 13, 2014 at 12:31 PM, Antoine Pitrou wrote: > On Mon, 13 Jan 2014 08:36:05 -0800 > Ethan Furman wrote: > > > On 01/13/2014 08:09 AM, Antoine Pitrou wrote: > > > On Mon, 13 Jan 2014 07:59:10 -0800 > > > Guido van Rossum wrote: > > >> On Mon, Jan 13, 2014 at 3:41 AM, Antoine Pitrou >

Re: [Python-Dev] PEP 460 reboot

2014-01-13 Thread Brett Cannon
On Mon, Jan 13, 2014 at 2:51 PM, Terry Reedy wrote: > On 1/13/2014 1:40 PM, Brett Cannon wrote: > > > So bytes formatting really needn't (and shouldn't, IMO) mirror str >> > formatting. >> > > This was my presumption in writing byteformat(). >

Re: [Python-Dev] PEP 460 reboot

2014-01-13 Thread Brett Cannon
On Mon, Jan 13, 2014 at 4:51 PM, Guido van Rossum wrote: > Terminology. Let's use the official terminology rather than making stuff > up. > > The docs at http://docs.python.org/3/library/string.html#formatspec > use the following terminology: > > Replacement field: {...}; contains field name, con

Re: [Python-Dev] PEP 460 reboot

2014-01-13 Thread Brett Cannon
On Mon, Jan 13, 2014 at 4:36 PM, Ethan Furman wrote: > On 01/13/2014 01:20 PM, Mark Lawrence wrote: > >> On 13/01/2014 21:01, Paul Moore wrote: >> >>> >>> I think this should be for 3.5, and should not involve an accelerated >>> release of 3.5 - we should get it into the 3.5 code early and let >>

Re: [Python-Dev] PEP 460 reboot

2014-01-14 Thread Brett Cannon
On Mon, Jan 13, 2014 at 5:14 PM, Guido van Rossum wrote: > On Mon, Jan 13, 2014 at 2:05 PM, Brett Cannon wrote: > > I have been going on the assumption that bytes.format() would change what > > '{}' meant for itself and would only interpolate bytes. That convenient &

Re: [Python-Dev] PEP 460 reboot

2014-01-14 Thread Brett Cannon
t; rare when string formatting is used to concatenate huge buffers. > 2. new operators {!b} and %b. This ones will just use ‘__bytes__’ and > Py_buffer. > > -- > Yury Selivanov > > On January 14, 2014 at 11:31:51 AM, Brett Cannon (br...@python.org) wrote: > > > > On Mon, Jan

Re: [Python-Dev] [Python-checkins] peps: Fill in PEP number (461).

2014-01-14 Thread Brett Cannon
I think this was supposed to be 461, not 460 =) On Tue, Jan 14, 2014 at 2:12 PM, guido.van.rossum < python-check...@python.org> wrote: > http://hg.python.org/peps/rev/a25f48998ad3 > changeset: 5346:a25f48998ad3 > user:Guido van Rossum > date:Tue Jan 14 11:12:09 2014 -0800 > su

Re: [Python-Dev] Changing Clinic's output

2014-01-14 Thread Brett Cannon
On Tue, Jan 14, 2014 at 3:22 PM, Larry Hastings wrote: > > On 01/11/2014 07:35 PM, Larry Hastings wrote: > > > On 01/08/2014 07:08 AM, Barry Warsaw wrote: > > How hard would it be to put together some sample branches that provide > concrete examples of the various options? > > My own opinion coul

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-14 Thread Brett Cannon
On Tue, Jan 14, 2014 at 2:55 PM, Ethan Furman wrote: > This PEP goes a but further than PEP 460 does, and hopefully spells things > out in enough detail so there is no confusion as to what is meant. > Are we going down the PEP route with the various ideas? Guido, do you want one from me as well

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-15 Thread Brett Cannon
bytes.format() below. I'll leave it to you to decide if they warrant using, leaving as an open question, or rejecting. On Tue, Jan 14, 2014 at 2:56 PM, Ethan Furman wrote: > Duh. Here's the text, as well. ;) > > > PEP: 461 > Title: Adding % and {} formatting to bytes > Version: $Revision$ > L

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-15 Thread Brett Cannon
On Wed, Jan 15, 2014 at 10:52 AM, Eric V. Smith wrote: > On 1/15/2014 9:45 AM, Brett Cannon wrote: > > > That's too vague; % interpolation does not support other format > > operators in the same way as str.format() does. % interpolation has > > specific code to su

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-15 Thread Brett Cannon
On Wed, Jan 15, 2014 at 10:57 AM, Ethan Furman wrote: > On 01/15/2014 06:45 AM, Brett Cannon wrote: > >> bytes.format() below. I'll leave it to you to decide if they warrant >> using, leaving as an open question, or rejecting. >> > > Thanks for your comments.

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-15 Thread Brett Cannon
On Wed, Jan 15, 2014 at 4:24 PM, Ethan Furman wrote: > On 01/15/2014 06:45 AM, Brett Cannon wrote: > >> >> I also think that a 'b' conversion be added to bytes.format(). This >> doesn't have the same issue as %b if you make {} >> implicitly mean {

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-15 Thread Brett Cannon
On Wed, Jan 15, 2014 at 5:00 PM, Steven D'Aprano wrote: > On Thu, Jan 16, 2014 at 10:55:31AM +1300, Greg Ewing wrote: > > Neil Schemenauer wrote: > > >Objects that implement __str__ can also implement __bytes__ if they > > >can guarantee that ASCII characters are always returned, > > > > I think _

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-16 Thread Brett Cannon
On Thu, Jan 16, 2014 at 2:51 AM, Ethan Furman wrote: > On 01/15/2014 06:45 AM, Brett Cannon wrote: > >> >> This is why I have argued that if you specify it as "if there is a format >> spec specified, then the return value from >> calling __format__() wi

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-16 Thread Brett Cannon
On Thu, Jan 16, 2014 at 4:56 AM, Nick Coghlan wrote: > > On 16 Jan 2014 17:53, "Ethan Furman" wrote: > > > > On 01/15/2014 06:45 AM, Brett Cannon wrote: > >> > >> > >> This is why I have argued that if you specify it as "if th

Re: [Python-Dev] PEP 461 - Adding % and {} formatting to bytes

2014-01-16 Thread Brett Cannon
On Thu, Jan 16, 2014 at 11:33 AM, Michael Urman wrote: > On Thu, Jan 16, 2014 at 8:45 AM, Brett Cannon wrote: > > Fine, if you're worried about bytes.format() overstepping by implicitly > > calling str.encode() on the return value of __format__() then you will > need >

<    1   2   3   4   5   6   7   8   9   10   >