Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Michael Hudson
Guido van Rossum <[EMAIL PROTECTED]> writes: > How does this sound to the non-AST-branch developers who have to > suffer the inevitable post-merge instability? I think it's now or > never -- waiting longer isn't going to make this thing easier (not > with several more language changes approved: wi

Re: [Python-Dev] Pythonic concurrency

2005-10-06 Thread Josiah Carlson
Michael Sparks <[EMAIL PROTECTED]> wrote: > > On Thursday 06 October 2005 23:15, Josiah Carlson wrote: > [... 6 specific use cases ...] > > If Kamaelia is able to handle all of the above mechanisms in both a > > blocking and non-blocking fashion, then I would guess it has the basic > > requiremen

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Kurt B. Kaiser
Guido van Rossum <[EMAIL PROTECTED]> writes: > I happen to agree with Kurt that we should first merge the head into > the branch; then the AST team can work on making sure the entire > test suite passes; then they can merge back into the head. I can be available to do this again. It would involv

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Brett Cannon
On 10/6/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > [Kurt] > > > Unless I'm missing something, we would need to merge HEAD to the AST > > > branch once more to pick up the changes in MAIN since the last merge, > > > and then make sure everything in the AST branch is passing the test > > > sui

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Phillip J. Eby
At 07:34 PM 10/6/2005 -0700, Guido van Rossum wrote: >How does this sound to the non-AST-branch developers who have to >suffer the inevitable post-merge instability? I think it's now or >never -- waiting longer isn't going to make this thing easier (not >with several more language changes approved:

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Guido van Rossum
[Kurt] > > Unless I'm missing something, we would need to merge HEAD to the AST > > branch once more to pick up the changes in MAIN since the last merge, > > and then make sure everything in the AST branch is passing the test > > suite. Otherwise we risk having MAIN broken for awhile following a >

Re: [Python-Dev] Pythonic concurrency

2005-10-06 Thread Michael Sparks
On Thursday 06 October 2005 23:15, Josiah Carlson wrote: [... 6 specific use cases ...] > If Kamaelia is able to handle all of the above mechanisms in both a > blocking and non-blocking fashion, then I would guess it has the basic > requirements for most concurrent applications. It can. I can easi

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Raymond Hettinger
> Unless I'm missing something, we would need to merge HEAD to the AST > branch once more to pick up the changes in MAIN since the last merge, > and then make sure everything in the AST branch is passing the test > suite. Otherwise we risk having MAIN broken for awhile following a > merge. IMO, m

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Kurt B. Kaiser
Jeremy Hylton <[EMAIL PROTECTED]> writes: > On 10/6/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: >> The only alternative to abandoning it that I see is to merge it back >> into main NOW, using the time that remains us until the 2.5 release to >> make it robust. That way, everybody can help out

Re: [Python-Dev] Pythonic concurrency

2005-10-06 Thread Josiah Carlson
Michael Sparks <[EMAIL PROTECTED]> wrote: > What I'd be interested in, is hearing how our system doesn't match with > the goals of the hypothetical concurrency system you'd like to see (if it > doesn't). The main reason I'm interested in hearing this, is because the > goals you listed are ones we

Re: [Python-Dev] Static builds on Windows (continued)

2005-10-06 Thread Marvin
> Date: Wed, 05 Oct 2005 00:21:20 +0200 > From: "Martin v. L?wis" <[EMAIL PROTECTED]> > Subject: Re: [Python-Dev] Static builds on Windows (continued) > Cc: python-dev@python.org > Message-ID: <[EMAIL PROTECTED]> > Content-Type: text/plain; charset=ISO-8859-1; format=flowed > > Marvin wrote: > >>

Re: [Python-Dev] Pythonic concurrency

2005-10-06 Thread Bruce Eckel
This does look quite fascinating, and I know there's a lot of really interesting work going on at the BBC now -- looks like some really pioneering stuff going on with respect to TV show distribution over the internet, new compression formats, etc. So yes indeed, this is quite high on my list to re

Re: [Python-Dev] Pythonic concurrency

2005-10-06 Thread Michael Sparks
Hi Bruce, On Thursday 06 October 2005 18:12, Bruce Eckel wrote: > Although I hope our conversation isn't done, as he suggests! ... > At some point when more ideas have been thrown about (and TIJ4 is > done) I hope to summarize what we've talked about in an article. I don't know if you saw my pre

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Jeremy Hylton
On 10/6/05, Guido van Rossum <[EMAIL PROTECTED]> wrote: > On 10/6/05, Neil Schemenauer <[EMAIL PROTECTED]> wrote: > > Nick Coghlan <[EMAIL PROTECTED]> wrote: > > > If we kill the branch for now, then anyone that wants to bring up the idea > > > again can write a PEP first > > > > I still have some

Re: [Python-Dev] Pythonic concurrency

2005-10-06 Thread Paolo Invernizzi
Just to add another 2 cents http://www.erights.org/talks/promises/paper/tgc05.pdf --- Paolo Invernizzi Bruce Eckel wrote: > Jeremy Jones published a blog discussing some of the ideas we've > talked about here: > http://www.oreillynet.com/pub/wlg/8002 > Although I hope our conversation isn't

[Python-Dev] Pythonic concurrency

2005-10-06 Thread Bruce Eckel
Jeremy Jones published a blog discussing some of the ideas we've talked about here: http://www.oreillynet.com/pub/wlg/8002 Although I hope our conversation isn't done, as he suggests! At some point when more ideas have been thrown about (and TIJ4 is done) I hope to summarize what we've talked abou

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Guido van Rossum
On 10/6/05, Neil Schemenauer <[EMAIL PROTECTED]> wrote: > Nick Coghlan <[EMAIL PROTECTED]> wrote: > > If we kill the branch for now, then anyone that wants to bring up the idea > > again can write a PEP first > > I still have some (very) small hope that it can be finished. If we > don't get it don

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Neil Schemenauer
Nick Coghlan <[EMAIL PROTECTED]> wrote: > If we kill the branch for now, then anyone that wants to bring up the idea > again can write a PEP first I still have some (very) small hope that it can be finished. If we don't get it done soon then I fear that it will never happen. I had hoped that a

Re: [Python-Dev] Lexical analysis and NEWLINE tokens

2005-10-06 Thread Phillip J. Eby
At 07:36 AM 10/6/2005 -0500, Matthew F. Barnes wrote: >I posted this question to python-help, but I think I have a better chance >of getting the answer here. > >I'm looking for clarification on when NEWLINE tokens are generated during >lexical analysis of Python source code. If you're talking abou

Re: [Python-Dev] Lexical analysis and NEWLINE tokens

2005-10-06 Thread Guido van Rossum
I think it is a relic from the distant past, when the lexer did generate NEWLINE for every blank line. I think the only case where you can still get a NEWLINE by itself is in interactive mode. This code is extremely convoluted and may be buggy in end cases; this could explain why you get a continua

Re: [Python-Dev] PEP 343 and __with__

2005-10-06 Thread Guido van Rossum
Just a quick note. Nick convinced me that adding __with__ (without losing __enter__ and __exit__!) is a good thing, especially for the decimal context manager. He's got a complete proposal for PEP changes which he'll post here. After a brief feedback period I'll approve his changes and he'll check

Re: [Python-Dev] Lexical analysis and NEWLINE tokens

2005-10-06 Thread Michael Hudson
"Matthew F. Barnes" <[EMAIL PROTECTED]> writes: > I posted this question to python-help, but I think I have a better chance > of getting the answer here. > > I'm looking for clarification on when NEWLINE tokens are generated during > lexical analysis of Python source code. In particular, I'm conf

Re: [Python-Dev] Unicode charmap decoders slow

2005-10-06 Thread Tony Nelson
At 8:36 AM +0200 10/5/05, Martin v. Löwis wrote: >Tony Nelson wrote: ... >> Encoding can be made fast using a simple hash table with external chaining. >> There are max 256 codepoints to encode, and they will normally be well >> distributed in their lower 8 bits. Hash on the low 8 bits (just mask

Re: [Python-Dev] Unicode charmap decoders slow

2005-10-06 Thread Walter Dörwald
M.-A. Lemburg wrote: > [...] >>Or we could have a function that recreates the dictionary from the string. > > Actually, I'd prefer that these operations be done by the > codec generator script, so that we don't have additional > startup time. The dictionaries should then no longer be > generated

[Python-Dev] Lexical analysis and NEWLINE tokens

2005-10-06 Thread Matthew F. Barnes
I posted this question to python-help, but I think I have a better chance of getting the answer here. I'm looking for clarification on when NEWLINE tokens are generated during lexical analysis of Python source code. In particular, I'm confused about some of the top-level components in Python's gr

Re: [Python-Dev] Unicode charmap decoders slow

2005-10-06 Thread Hye-Shik Chang
On 10/6/05, M.-A. Lemburg <[EMAIL PROTECTED]> wrote: > Hye-Shik Chang wrote: > > (encoding, fastmap codec) > > > > % ./python Lib/timeit.py -s "s='a'*53*1024; e='iso8859_10_fc'; > > u=unicode(s, e)" "u.encode(e)" > > 1000 loops, best of 3: 536 usec per loop > > > > (encoding, utf-8 codec) > > > > %

Re: [Python-Dev] Python 2.5 and ast-branch

2005-10-06 Thread Nick Coghlan
[Brett] > To answer Nick's email here, I didn't respond to that initial email > because it seemed specifically directed at Guido and not me. Fair enough. I think I was actually misrembering the sequence of events leading up to 2.4a1, so the question was less appropriate for Guido than I thought

Re: [Python-Dev] Unicode charmap decoders slow

2005-10-06 Thread M.-A. Lemburg
Hye-Shik Chang wrote: > On 10/6/05, M.-A. Lemburg <[EMAIL PROTECTED]> wrote: > >>Hye-Shik, could you please provide some timeit figures for >>the fastmap encoding ? >> Thanks for the timings. > (before applying Walter's patch, charmap decoder) > > % ./python Lib/timeit.py -s "s='a'*53*1024; e='

Re: [Python-Dev] Unicode charmap decoders slow

2005-10-06 Thread M.-A. Lemburg
Walter Dörwald wrote: > Martin v. Löwis wrote: > >> Hye-Shik Chang wrote: >> >>> If the encoding optimization can be easily done in Walter's approach, >>> the fastmap codec would be too expensive way for the objective because >>> we must maintain not only fastmap but also charmap for backward >>>

Re: [Python-Dev] Unicode charmap decoders slow

2005-10-06 Thread Walter Dörwald
Martin v. Löwis wrote: > Hye-Shik Chang wrote: > >> If the encoding optimization can be easily done in Walter's approach, >> the fastmap codec would be too expensive way for the objective because >> we must maintain not only fastmap but also charmap for backward >> compatibility. > > IMO, whethe

Re: [Python-Dev] Removing the block stack

2005-10-06 Thread Michael Hudson
Neal Norwitz <[EMAIL PROTECTED]> writes: > On 10/5/05, Phillip J. Eby <[EMAIL PROTECTED]> wrote: >> At 09:50 AM 10/4/2005 +0100, Michael Hudson wrote: >> >(anyone still thinking about removing the block stack?). >> >> I'm not any more. My thought was that it would be good for performance, by >> r

Re: [Python-Dev] unifying str and unicode

2005-10-06 Thread Stephen J. Turnbull
> "M" == "M.-A. Lemburg" <[EMAIL PROTECTED]> writes: M> From what I've read on the web about the Python Unicode M> implementation we have one of the better ones compared to other M> languages implementations and their choices and design M> decisions. Yes, indeed! Speaking-as-

Re: [Python-Dev] Unicode charmap decoders slow

2005-10-06 Thread Walter Dörwald
Martin v. Löwis wrote: > Walter Dörwald wrote: > >> OK, here's a patch that implements this enhancement to >> PyUnicode_DecodeCharmap(): http://www.python.org/sf/1313939 > > Looks nice! > >> Creating the decoding_map as a string should probably be done by >> gencodec.py directly. This way the

Re: [Python-Dev] Removing the block stack (was Re: PEP 343 and __with__)

2005-10-06 Thread Martin v. Löwis
Neal Norwitz wrote: > My thoughts are to dynamically allocate the Python stack memory (e.g., > void *stack = malloc(128MB)). Then all calls within each thread uses > its own stack. So things would be pushed onto the stack like they are > currently, but we wouldn't need to do create a tuple to pas

Re: [Python-Dev] Removing the block stack (was Re: PEP 343 and __with__)

2005-10-06 Thread Phillip J. Eby
At 10:09 PM 10/5/2005 -0700, Neal Norwitz wrote: >I've also been thinking about avoiding tuple creation when calling >python functions. The change I have in mind would probably have to >wait until p3k, but could yield some speed ups. > >Warning: half baked idea follows. Yeah, I've been baking th

Re: [Python-Dev] Unicode charmap decoders slow

2005-10-06 Thread Martin v. Löwis
Hye-Shik Chang wrote: > If the encoding optimization can be easily done in Walter's approach, > the fastmap codec would be too expensive way for the objective because > we must maintain not only fastmap but also charmap for backward > compatibility. IMO, whether a new function is added or whether