[Python-Dev] [PEP 3148] futures - execute computations asynchronously

2010-03-04 Thread Brian Quinlan
Hi all, I recently submitted a daft PEP for a package designed to make it easier to execute Python functions asynchronously using threads and processes. It lets the user focus on their computational problem without having to build explicit thread/process pools and work queues. The package

Re: [Python-Dev] doctest, unicode repr, and 2to3

2010-03-04 Thread Glyph Lefkowitz
On Mar 4, 2010, at 11:30 PM, Barry Warsaw wrote: > If you really want to test that it's a unicode, shouldn't you actually test > its type? (I'm not sure what would happen with that under 2to3.) Presumably 2to3 will be smart enough to translate 'unicode' to 'str' and 'bytes' to... 'bytes'. Jus

Re: [Python-Dev] doctest, unicode repr, and 2to3

2010-03-04 Thread Barry Warsaw
On Mar 05, 2010, at 05:11 AM, Martin v. Löwis wrote: >Johan Harjano ran into an interesting problem when trying to run the >Django test suite under Python 3.1. > >Django has doctests of the form > a6.headline >u'Default headline' > >Even when converting the doctest with 2to3, the expected out

[Python-Dev] doctest, unicode repr, and 2to3

2010-03-04 Thread Martin v. Löwis
Johan Harjano ran into an interesting problem when trying to run the Django test suite under Python 3.1. Django has doctests of the form >>> a6.headline u'Default headline' Even when converting the doctest with 2to3, the expected output is unmodified. However, in 3.x, the expected output will ch

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Stephen J. Turnbull
Brett Cannon writes: > I prefer the subject so that I can easily skim them to see if someone edited > a file I really care about, but if that is not possible then the body is > acceptable, especially if it is the first thing in the body (that would let > me at least see some of it in the initi

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Brett Cannon
On Thu, Mar 4, 2010 at 13:56, Benjamin Peterson wrote: > 2010/3/4 Dirkjan Ochtman : > > On Thu, Mar 4, 2010 at 22:44, Benjamin Peterson > wrote: > >> +1 to bringing back affected files. It helps tell at a glance whether > >> a changeset is interesting or not. > > > > Do they need to be in the su

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Benjamin Peterson
2010/3/4 Dirkjan Ochtman : > On Thu, Mar 4, 2010 at 22:44, Benjamin Peterson wrote: >> +1 to bringing back affected files. It helps tell at a glance whether >> a changeset is interesting or not. > > Do they need to be in the subject, or would it be fine to have them in > the message? Both is good

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Dirkjan Ochtman
On Thu, Mar 4, 2010 at 22:44, Benjamin Peterson wrote: > +1 to bringing back affected files. It helps tell at a glance whether > a changeset is interesting or not. Do they need to be in the subject, or would it be fine to have them in the message? Cheers, Dirkjan ___

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Benjamin Peterson
2010/3/4 Dirkjan Ochtman : > Well, I think it looks rather ugly, and Tarek said he'd like the first > line of the commit message in the subject instead, so that's what I've > implemented right now. But then if there's a majority who want the > files, I'm happy to put them back. +1 to bringing back

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Dirkjan Ochtman
First off, this was just a first sample, it was by no means the definitive format. Second, the diffs are already back, in the next message (this first one was per changegroup, not per changeset -- new ones will be per changeset). On Thu, Mar 4, 2010 at 21:20, Brett Cannon wrote: > 1) I miss not

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Barry Warsaw
On Mar 04, 2010, at 03:43 PM, Eric Smith wrote: >Are the diffs gone for some deliberate reason? > >I realize the link tells me the changes, but I'll review a lot more code >if the diffs show up in my inbox than if I have to fire up a browser, >especially from my phone. Agreed, please restore th

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Nick Coghlan
Brett Cannon wrote: > 1) I miss not having the affected files listed in the subject line. > > 2) The To field is set to h...@python.org which > gets rejected as an invalid email address if you reply. Would be better > to set it to python-checkins so that the habitual reply

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Eric Smith
Are the diffs gone for some deliberate reason? I realize the link tells me the changes, but I'll review a lot more code if the diffs show up in my inbox than if I have to fire up a browser, especially from my phone. Eric. Brett Cannon wrote: 1) I miss not having the affected files listed in

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Nick Coghlan
Brett Cannon wrote: > 1) I miss not having the affected files listed in the subject line. > > 2) The To field is set to h...@python.org which > gets rejected as an invalid email address if you reply. Would be better > to set it to python-checkins so that the habitual reply

Re: [Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Fred Drake
On Thu, Mar 4, 2010 at 3:20 PM, Brett Cannon wrote: > 1) I miss not having the affected files listed in the subject line. > 2) The To field is set to h...@python.org which gets rejected as an invalid > email address if you reply. Would be better to set it to python-checkins so > that the habitual

[Python-Dev] Desired changes to Hg emails to python-checkins

2010-03-04 Thread Brett Cannon
1) I miss not having the affected files listed in the subject line. 2) The To field is set to h...@python.org which gets rejected as an invalid email address if you reply. Would be better to set it to python-checkins so that the habitual reply to a checkin won't get rejected. At least I would lik

Re: [Python-Dev] __file__

2010-03-04 Thread Barry Warsaw
On Mar 04, 2010, at 11:25 PM, Nick Coghlan wrote: >It's a moot point anyway - Guido has pronounced that the bytecode-only >support will be left alone by PEP 3147 even if the other caching changes >are eventually accepted. Right. I should have stopped while I was ahead. We'll just keep what's in

Re: [Python-Dev] __file__ and bytecode-only

2010-03-04 Thread Nick Coghlan
Barry Warsaw wrote: > On Mar 03, 2010, at 07:37 PM, Jim Jewett wrote: > >> I understand the need to ship without source -- but why does that >> require supporting .pyc (or .pyo) -only? >> >> Couldn't vendors just replace the real .py files with empty files? > > Yes, I think that's a possibility.

Re: [Python-Dev] __file__

2010-03-04 Thread Nick Coghlan
Henning von Bargen wrote: > If the ZIP contains only bytecode files, it is just not intended > for changing any code, so I don't think this is an argument. > If you have access to the source code, you still can use that instead > of messing around with byte code. That doesn't apply when it is the