Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Mark Hammond
I wrote: > Bob writes: Ack - sorry about that - the HTML mail confused me :) It was Brett, of course. Mark ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailm

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Mark Hammond
Bob writes: > I don't know how JavaScript is doing it yet. The critical thing > for me for this month was trying to come up with a security model. I don't fully understand how JS does it either, certainly not in any detail. I know that it uses the concept of a "principal" (the IDL file can be se

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Martin v. Löwis
Greg Ewing wrote: > BTW, I'm not sure if 'xturtle' is such a good name. > There's a tradition of X Windows executables having > names starting with 'x', whereas this is presumably > platform-independent. > > Maybe 'turtleplus' or something? When it goes into Python, it will be 'turtle'. Regards,

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Greg Ewing
Martin v. Löwis wrote: > xturtle BTW, I'm not sure if 'xturtle' is such a good name. There's a tradition of X Windows executables having names starting with 'x', whereas this is presumably platform-independent. Maybe 'turtleplus' or something? -- Greg

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Greg Ewing
Jim Jewett wrote: > IMHO, I would prefer that it limit disk consumption; a deleted or > overwritten file would not count against the process, but even a > temporary spike would need to be less than the cap. The problem is that there's no easy way to reliably measure disk consumption by a particul

[Python-Dev] xturtle.py

2006-06-28 Thread Jim Jewett
Raymond wrote: > One other thought -- at PyCon, I talked with a group of > educators. While they needed some minor tweaks to the Turtle > module, there were no requests for an extensive rewrite or a > fatter API. The name of the game was to have a single module > with a minimal toolset supportin

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Greg Ewing
Talin wrote: > The case -> sub mapping doesn't need to be defined every time - that's > the point, you as the programmer decide when and how to construct the > dictionary, Then you seem to be proposing a variation on the constant-only case option, with a more convoluted control flow. -- Greg _

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Greg Ewing
Nick Coghlan wrote: > By 'current namespace' I really do mean locals() - the cell objects themselves > would be local variables from the point of view of the currently executing > code. This is wrong. Cells are *parameters* implicitly passed in by the calling function. They may temporarily be re

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?) ATTENTION PLEASE!

2006-06-28 Thread Gregor Lingl
Fredrik Lundh schrieb: > Gregor Lingl wrote: > > >> What a shame!! An immanent bug, persistent >> for years now! >> >> Is this what Anthony Baxter calls >> "the most solid Python release ever" >> > > do you really think stuff like this helps your cause ? > > Perhaps it dosn't help the tu

Re: [Python-Dev] xturtle.py

2006-06-28 Thread Martin v. Löwis
[EMAIL PROTECTED] wrote: > As a compromise. we could tack Gregor Lingl's module under > the Tools directory. This makes the tool more readily available > for student use and allows it a more liberal zone to evolve than > if it were in the standard library. That could also work. See my other com

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?) ATTENTION PLEASE!

2006-06-28 Thread Georg Brandl
Guido van Rossum wrote: > It was already patched by the other Georg. Thanks for the quick fix, georgbot! My pleasure, even if there's a difference between "Georg" and "Gregor" ;) cheers, Georg ___ Python-Dev mailing list Python-Dev@python.org http://ma

Re: [Python-Dev] once [was: Simple Switch statementZ]

2006-06-28 Thread Ron Adam
> I believe at least one poster has pointed out that 'once' (if defined > suitably) could be used as a better way to do this: > > def index_functions(n): > return [(lambda: once i) for i in range(n)] > > But delaying the evaluation of the once argument until the function is > called would b

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?) ATTENTION PLEASE!

2006-06-28 Thread Martin v. Löwis
Gregor Lingl wrote: > For example: put turtle.py and xturtle.py both into beta2 and > see which one stands better the (beta)test of time. Or perhaps you have > an even better idea! As a compromise, we could put an ad into the turtle document (a "see also" link). Regards, Martin _

[Python-Dev] xturtle.py

2006-06-28 Thread python
[Collin Winter] >> While I have no opinion on Gregor's app, and while I fully agree that >> new language features and stdlib modules should generally stay out of >> bug-fix point releases, xturtle doesn't seem to rise to that level >> (and hence, those restrictions). [Martin] > It's a stdlib mo

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?) ATTENTION PLEASE!

2006-06-28 Thread Martin v. Löwis
Gregor Lingl wrote: > Sorry Martin, but to me this seems not to be the right way to manage > things. As you explain later, this is precisely the right way; it is unfortunate that it isn't always followed. > (Who reviewed it? This is a _newly_added_ function - > did nobody try it out yet? Incredib

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?) ATTENTION PLEASE!

2006-06-28 Thread Guido van Rossum
It was already patched by the other Georg. Thanks for the quick fix, georgbot! --Guido On 6/28/06, Bob Ippolito <[EMAIL PROTECTED]> wrote: > > On Jun 28, 2006, at 1:05 PM, Gregor Lingl wrote: > > > Martin v. Löwis schrieb: > >> Collin Winter wrote: > >> > >>> While I have no opinion on Gregor's a

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?) ATTENTION PLEASE!

2006-06-28 Thread Bob Ippolito
On Jun 28, 2006, at 1:05 PM, Gregor Lingl wrote: > Martin v. Löwis schrieb: >> Collin Winter wrote: >> >>> While I have no opinion on Gregor's app, and while I fully agree >>> that >>> new language features and stdlib modules should generally stay >>> out of >>> bug-fix point releases, xturtl

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/28/06, Trent Mick <[EMAIL PROTECTED]> wrote: Brett Cannon wrote:> > > The idea is that there be a separate Python interpreter per web> > > browser page instance.>> > I think there may be scaling issues there. _javascript_ isn't doing that > > is it, do you know? As well, that doesn't s

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?) ATTENTION PLEASE!

2006-06-28 Thread Fredrik Lundh
Gregor Lingl wrote: > What a shame!! An immanent bug, persistent > for years now! > > Is this what Anthony Baxter calls > "the most solid Python release ever" do you really think stuff like this helps your cause ? ___ Python-Dev mailing list Python-

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Trent Mick
Brett Cannon wrote: > > > The idea is that there be a separate Python interpreter per web > > > browser page instance. > > > I think there may be scaling issues there. JavaScript isn't doing that > > is it, do you know? As well, that doesn't seem like it would translate > > well to sha

Re: [Python-Dev] ImportWarning flood

2006-06-28 Thread Aahz
On Wed, Jun 28, 2006, James Y Knight wrote: > > I just found another reason to dislike the warnings: my homedir on > one machine has a lot of random directories in it. One of them is > named "readline". Every time I run python 2.5, it now helpfully notes: >sys:1: ImportWarning: Not importin

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?) ATTENTION PLEASE!

2006-06-28 Thread Gregor Lingl
Martin v. Löwis schrieb: Collin Winter wrote: While I have no opinion on Gregor's app, and while I fully agree that new language features and stdlib modules should generally stay out of bug-fix point releases, xturtle doesn't seem to rise to that level (and hence, those restrictions).

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/28/06, Bill Janssen <[EMAIL PROTECTED]> wrote: > Yep, it would be.  Then again, Mark Hammond has already done a bunch of work> for pyXPCOM, so getting Python compiled right into Firefox itself shouldn't> be too bad.Of course, that's the road Sun first went down with Java, and that turned out n

Re: [Python-Dev] ImportWarning flood

2006-06-28 Thread James Y Knight
On Jun 25, 2006, at 9:47 PM, James Y Knight wrote: > > On Jun 24, 2006, at 1:29 PM, Ralf W. Grosse-Kunstleve wrote: > >> --- Jean-Paul Calderone <[EMAIL PROTECTED]> wrote: >>> I think it is safe to say that Twisted is more widely used than >>> anything >>> Google has yet released. Twisted also h

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Andreas Raab
Guido van Rossum wrote: > On 6/28/06, Brett Cannon <[EMAIL PROTECTED]> wrote: >> On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: >>> - File size should be rounded up to some block size (512 if you don't >>> have filesystem specific information) before adding to the total. >> Why? > > Becau

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Martin v. Löwis
Collin Winter wrote: > While I have no opinion on Gregor's app, and while I fully agree that > new language features and stdlib modules should generally stay out of > bug-fix point releases, xturtle doesn't seem to rise to that level > (and hence, those restrictions). It's a stdlib module, even if

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Bill Janssen
> Yep, it would be. Then again, Mark Hammond has already done a bunch of work > for pyXPCOM, so getting Python compiled right into Firefox itself shouldn't > be too bad. Of course, that's the road Sun first went down with Java, and that turned out not-so-well for them. I think the plug-in approa

Re: [Python-Dev] once [was: Simple Switch statementZ]

2006-06-28 Thread Guido van Rossum
On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote: > On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote: > It basically requires a reserved word. > > def f(a, b="key", __func__.extra=i): > if __func__.extra < 43: ... > > > And an

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Bob Ippolito
On Jun 28, 2006, at 10:54 AM, Brett Cannon wrote:On 6/28/06, Trent Mick <[EMAIL PROTECTED]> wrote: Brett Cannon wrote: Mark (and me a little bit) has been sketching out creating a "Python forMozilla/Firefox" extension for installing an embedded Python into anexisting Firefox installation on the pyx

Re: [Python-Dev] once [was: Simple Switch statementZ]

2006-06-28 Thread Jim Jewett
On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: > On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote: > > On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > > def index_functions(n): > > > return [(lambda i=i: i) for i in range(n)] > > > which works but has the disadvantage o

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Eric Sumner
> > Forget subroutines for a moment - the main point of the thread was the > > idea that the dispatch table was built explicitly rather than > > automatically - that instead of arguing over first-use vs. > > function-definition, we let the user decide. I'm sure that my specific > > proposal isn't t

Re: [Python-Dev] PEP 328 and PEP 338, redux

2006-06-28 Thread Georg Brandl
Guido van Rossum wrote: > On 6/27/06, Greg Ewing <[EMAIL PROTECTED]> wrote: >> Giovanni Bajo wrote: >> >> > This is where I wonder why the "def __main__()" PEP was rejected in the >> > first place. It would have solved this problem as well. >> >> Could this be reconsidered for Py3k? > > You have a

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/28/06, Trent Mick <[EMAIL PROTECTED]> wrote: Brett Cannon wrote:> The plan is to allow pure Python code to be embedded into web pages like> _javascript_. ...> ...Then again, Mark Hammond has already done a bunch of work for pyXPCOM, so getting Python compiled right into Firefox itself shouldn'

Re: [Python-Dev] RFC: trunk checkins between now and 2.5 final

2006-06-28 Thread Tim Peters
Only one gripe: [Anthony Baxter] > ... > Once we hit release candidate 1, the trunk gets branched to > reease25-maint. Save the branch for 2.5 final (i.e., the 2.5final tag and the release25-maint branch start life exactly the same). Adding a new step before it's possible to fix rc1 critical bug

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: On 6/28/06, Brett Cannon <[EMAIL PROTECTED]> wrote:> On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote:> > - File size should be rounded up to some block size (512 if you don't > > have filesystem specific information) before adding to th

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote: On 6/28/06, Brett Cannon <[EMAIL PROTECTED]> wrote:> On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote:> > - File size should be rounded up to some block size (512 if you don't > > have filesystem specific information) before adding to the tota

Re: [Python-Dev] RFC: trunk checkins between now and 2.5 final

2006-06-28 Thread Guido van Rossum
On 6/28/06, Anthony Baxter <[EMAIL PROTECTED]> wrote: > As far as people to sign off on things, Neal, myself or Guido should > be the ones to do it. Course, Guido will probably decide he doesn't > want this dubious honour . Right. But I agree with the policy. FWIW, I think Nick's change for -m is

[Python-Dev] RFC: trunk checkins between now and 2.5 final

2006-06-28 Thread Anthony Baxter
This is a request for comments - this is my current thinking on a policy for checkins to the trunk between now and the release of 2.5 final. Now that we're in beta: If you don't add an entry to Misc/NEWS, a test (if relevant or possible) and docs (if relevant), the checkin is probably g

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Guido van Rossum
On 6/28/06, Brett Cannon <[EMAIL PROTECTED]> wrote: > On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > - File size should be rounded up to some block size (512 if you don't > > have filesystem specific information) before adding to the total. > > Why? Because that's how filesystems work

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Trent Mick
Brett Cannon wrote: > The plan is to allow pure Python code to be embedded into web pages like > JavaScript. ... > ...Then again, Mark Hammond has already done a bunch of work for pyXPCOM, so > getting Python compiled right into Firefox itself shouldn't be too bad. > > If this really takes off,

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Guido van Rossum
On 6/28/06, Talin <[EMAIL PROTECTED]> wrote: > Guido van Rossum wrote: > > Let's just drop the switchable subroutine proposal. It's not viable. > > Perhaps not - but at the same time, when discussing new language > features, let's not just limit ourselves to what other languages have > done already

Re: [Python-Dev] once [was: Simple Switch statementZ]

2006-06-28 Thread Guido van Rossum
On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote: > On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > > def index_functions(n): > > return [(lambda i=i: i) for i in range(n)] > > > which works but has the disadvantage of returning a list of functions > > of 0 or 1 argument > > > I b

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Talin
Guido van Rossum wrote: > Let's just drop the switchable subroutine proposal. It's not viable. > Perhaps not - but at the same time, when discussing new language features, let's not just limit ourselves to what other languages have done already. Forget subroutines for a moment - the main point

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Jim Jewett
On 6/28/06, Brett Cannon <[EMAIL PROTECTED]> wrote: > On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: > > - File size should be rounded up to some block size (512 if you don't > > have filesystem specific information) before adding to the total. > Why? That reflects the amount of disk I

Re: [Python-Dev] PEP 328 and PEP 338, redux

2006-06-28 Thread Giovanni Bajo
Guido van Rossum wrote: >>> This is where I wonder why the "def __main__()" PEP was rejected in >>> the first place. It would have solved this problem as well. >> >> Could this be reconsidered for Py3k? > > You have a point. AFAICT, there's nothing preventing it from being added in 2.6. It won't

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Anthony Baxter
On Thursday 29 June 2006 03:03, Collin Winter wrote: > This may be a stupid question, but we're talking about replacing > the turtle.py in Lib/lib-tk/, right? The one that's basically just > a GUI demo / introduction to programming tool? > > If so, can someone explain to me how improving something

Re: [Python-Dev] once [was: Simple Switch statementZ]

2006-06-28 Thread Jim Jewett
On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: > def index_functions(n): > return [(lambda i=i: i) for i in range(n)] > which works but has the disadvantage of returning a list of functions > of 0 or 1 argument > I believe at least one poster has pointed out that 'once' (if define

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Aahz
On Wed, Jun 28, 2006, Collin Winter wrote: > > This may be a stupid question, but we're talking about replacing the > turtle.py in Lib/lib-tk/, right? The one that's basically just a GUI > demo / introduction to programming tool? > > If so, can someone explain to me how improving something like th

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Collin Winter
On 6/28/06, Josiah Carlson <[EMAIL PROTECTED]> wrote: > > Gregor Lingl <[EMAIL PROTECTED]> wrote: > > Could you imagine - downgrading it's 'featureness' - to put it into 2.5.1 > > or something like this? > > Changing features/abilities of Python in micro releases (2.5 -> 2.5.1), > aside from bugfix

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Gregor Lingl
Josiah Carlson schrieb: > Gregor Lingl <[EMAIL PROTECTED]> wrote: > >> Could you imagine - downgrading it's 'featureness' - to put it into 2.5.1 >> or something like this? >> > > Changing features/abilities of Python in micro releases (2.5 -> 2.5.1), > aside from bugfixes, is a no-no. I un

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/27/06, Bill Janssen <[EMAIL PROTECTED]> wrote: > The plan is to allow pure Python code to be embedded into web pages like> _javascript_.  I am not going for the applet approach like Java.Java support is now just a plug-in.  Should be easy to make a Python plug-in system that works the same way

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/28/06, Guido van Rossum <[EMAIL PROTECTED]> wrote: On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote:> On 6/27/06, Neal Norwitz <[EMAIL PROTECTED]> wrote:> > On 6/27/06, Brett Cannon < [EMAIL PROTECTED]> wrote:> > >> > > > (5)  I think file creation/writing should be capped rather than> > > > b

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote: On 6/27/06, Neal Norwitz <[EMAIL PROTECTED]> wrote:> On 6/27/06, Brett Cannon <[EMAIL PROTECTED]> wrote:> >> > > (5)  I think file creation/writing should be capped rather than > > > binary; it is reasonable to say "You can create a single temp file

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Guido van Rossum
Let's just drop the switchable subroutine proposal. It's not viable. On 6/28/06, Josiah Carlson <[EMAIL PROTECTED]> wrote: > > Talin <[EMAIL PROTECTED]> wrote: > > Josiah Carlson wrote: > > > Talin <[EMAIL PROTECTED]> wrote: > > > > > >>My version of this is to add to Python the notion of a simple

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Brett Cannon
On 6/27/06, Neal Norwitz <[EMAIL PROTECTED]> wrote: On 6/27/06, Brett Cannon <[EMAIL PROTECTED]> wrote:>> > (5)  I think file creation/writing should be capped rather than> > binary; it is reasonable to say "You can create a single temp file up > > to 4K" or "You can create files, but not more than

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Guido van Rossum
On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote: > On 6/27/06, Neal Norwitz <[EMAIL PROTECTED]> wrote: > > On 6/27/06, Brett Cannon <[EMAIL PROTECTED]> wrote: > > > > > > > (5) I think file creation/writing should be capped rather than > > > > binary; it is reasonable to say "You can create a sin

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Josiah Carlson
Gregor Lingl <[EMAIL PROTECTED]> wrote: > Could you imagine - downgrading it's 'featureness' - to put it into 2.5.1 > or something like this? Changing features/abilities of Python in micro releases (2.5 -> 2.5.1), aside from bugfixes, is a no-no. See the Python 2.2 -> 2.2.1 availability of True/

Re: [Python-Dev] PEP 328 and PEP 338, redux

2006-06-28 Thread Guido van Rossum
On 6/28/06, Nick Coghlan <[EMAIL PROTECTED]> wrote: > The workaround to replace __name__ with __module_name__ in order to enable > relative imports turned out to be pretty ugly, so I also worked up a patch to > import.c to get it to treat __module_name__ as an override for __name__ when > __name__

Re: [Python-Dev] School IIb?

2006-06-28 Thread Guido van Rossum
On 6/28/06, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > I just wish I could figure out what school my original micro-PEP belongs > to (but as long as my implementation note is still just a draft, I guess no- > body else can figure that out either... ;-) There aren't just schools; there are alternat

Re: [Python-Dev] once [was: Simple Switch statementZ]

2006-06-28 Thread Guido van Rossum
On 6/28/06, Jim Jewett <[EMAIL PROTECTED]> wrote: > On 6/25/06, Ka-Ping Yee wrote: > > > def f(x): > > def g(y): > > return y + once x > > return g > > > Does "once" mean not really once here, but "once for each new function > > object that's created for g"? > > Unt

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Josiah Carlson
Talin <[EMAIL PROTECTED]> wrote: > Josiah Carlson wrote: > > Talin <[EMAIL PROTECTED]> wrote: > > > >>My version of this is to add to Python the notion of a simple > >>old-fashioned subroutine - that is, a function with no arguments and no > >>additional scope, which can be referred to by name.

Re: [Python-Dev] xturtle.py - a replacement for turtle.py

2006-06-28 Thread Raymond Hettinger
Gregor Lingl wrote: >I would appreciate it very much if xturtle.py could go into Python2.5. > > +1 The need for turtle.py improvements was discussed at the last PyCon. It would be a nice plus for people teaching programming to kids. In theory, it is a little late to be adding new modules.

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Fredrik Lundh
Gregor Lingl wrote: > Already now, only one week after publishing it I have some very positive > feedback and people start to use it. So I think there is some demand for > it. some demand != should be added to the core distribution a few days after its first release. (and if everything that someo

[Python-Dev] once [was: Simple Switch statementZ]

2006-06-28 Thread Jim Jewett
On 6/25/06, Ka-Ping Yee wrote: > def f(x): > def g(y): > return y + once x > return g > Does "once" mean not really once here, but "once for each new function > object that's created for g"? Until today, it hadn't really occurred to me that once could mean once p

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Gregor Lingl
Anthony Baxter schrieb: > On Wednesday 28 June 2006 20:57, Gregor Lingl wrote: > >> I would very much appreciate if xturtle.py could go into >> Python 2.5 >> > > Unfortunately Python 2.5b1 came out last week. Now that we're in beta, > we're feature frozen (unless some horrible issue comes

Re: [Python-Dev] [Python-checkins] r47142 - in python/trunk: Doc/lib/librunpy.tex Lib/runpy.py Lib/test/test_runpy.py

2006-06-28 Thread Anthony Baxter
On Wednesday 28 June 2006 20:41, nick.coghlan wrote: > Author: nick.coghlan > Date: Wed Jun 28 12:41:47 2006 > New Revision: 47142 > > Modified: >python/trunk/Doc/lib/librunpy.tex >python/trunk/Lib/runpy.py >python/trunk/Lib/test/test_runpy.py > Log: > Make full module name available as

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Anthony Baxter
On Wednesday 28 June 2006 20:57, Gregor Lingl wrote: > I would very much appreciate if xturtle.py could go into > Python 2.5 Unfortunately Python 2.5b1 came out last week. Now that we're in beta, we're feature frozen (unless some horrible issue comes up that means we really need to do a feature

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Guido van Rossum
On 6/28/06, Nick Coghlan <[EMAIL PROTECTED]> wrote: > Guido van Rossum wrote: > > I think we all agree > > that side effects of case expressions is one way how we can deduce the > > compiler's behind-the-scenes tricks (even School Ib is okay with > > this). So I don't accept this as proof that Opti

Re: [Python-Dev] School IIb?

2006-06-28 Thread Fredrik Lundh
Guido van Rossum wrote: >> that's not true for all programming languages that has a switch construct, >> though; >> the common trait is that you're dispatching on a single value, not >> necessarily that >> there cannot be potentially overlapping case conditions. > > You have a point. that can h

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Guido van Rossum
Looks like this doesn't help at all when pre-computing the dispatch dict based on named constants. So this is a no-go. I should add that ABC had such named subroutines (but not for switching); I dropped them to simplify things. They're not an intrinsically undesirable or even unnecessary thing IMO

Re: [Python-Dev] School IIb?

2006-06-28 Thread Guido van Rossum
On 6/28/06, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > Phillip J. Eby wrote: > > > Hear, hear! We already have if/elif, we don't need another way to spell > > it. The whole point of switch is that it asserts that exactly *one* case > > is supposed to match > > that's not true for all programming

Re: [Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread A.M. Kuchling
On Wed, Jun 28, 2006 at 12:57:23PM +0200, Gregor Lingl wrote: > I would very much appreciate if xturtle.py could go into > Python 2.5 That decision is up to Anthony Baxter, the release manager. Unfortunately 2.5beta1 is already out, and the developers try to avoid large changes during the beta se

Re: [Python-Dev] doc for new restricted execution design for Python

2006-06-28 Thread Jim Jewett
On 6/27/06, Neal Norwitz <[EMAIL PROTECTED]> wrote: > On 6/27/06, Brett Cannon <[EMAIL PROTECTED]> wrote: > > > > > (5) I think file creation/writing should be capped rather than > > > binary; it is reasonable to say "You can create a single temp file up > > > to 4K" or "You can create files, but

Re: [Python-Dev] xturtle.py - a replacement for turtle.py

2006-06-28 Thread Martin v. Löwis
Gregor Lingl wrote: > I would appreciate it very much if xturtle.py could go into Python2.5. > I'm ready to do the amendments, which may emerge as necessary from the > dicussion here. I see little chance for that. Python 2.5 is feature-frozen. Regards, Martin ___

Re: [Python-Dev] ImportWarning flood

2006-06-28 Thread Martin v. Löwis
Ralf W. Grosse-Kunstleve wrote: >> There can be many reasons why an import could fail: there might be >> no read permission for the file, > > The warning in 2.5b1 doesn't fire in this case: Sure, but it would produce your "note", right? And the note would be essentially wrong. Instead, the Import

Re: [Python-Dev] PEP 328 and PEP 338, redux

2006-06-28 Thread Nick Coghlan
Nick Coghlan wrote: > Guido van Rossum wrote: >> However, I'm fine with setting *another* variable to the full package >> name so someone who *really* wants to do relative imports here knows >> the package name. > > OK, I'll do that. Any objections to __module_name__ as the name of the > variable?

Re: [Python-Dev] ImportWarning flood

2006-06-28 Thread Ralf W. Grosse-Kunstleve
--- "Martin v. L�wis" <[EMAIL PROTECTED]> wrote: > Ralf W. Grosse-Kunstleve wrote: > > If there is a consenus, I'd create a new exception > ImportErrorNoModule(name) > > that is used consistently from all places. This would ensure uniformity of > the > > message in the future. > > A correction

[Python-Dev] Oh-why that?? Please ignore one of the two

2006-06-28 Thread Gregor Lingl
Sorry (dunno why) Gregor ___ 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%40mail-archive.com

[Python-Dev] xturtle.py - a replacement for turtle.py

2006-06-28 Thread Gregor Lingl
xturtle.py, extended turtle graphics is a new Tkinter based turtle graphics module for Python xturtle.py (Version 0.91) can be found at: http://sourceforge.net/tracker/?group_id=5470&atid=305470 (Request ID 1513695, and 1513699 for the docs) and at http://ada.rg16.asn-wien.ac.at/~python/xturtle

[Python-Dev] xturtle.py a replacement for turtle.py(!?)

2006-06-28 Thread Gregor Lingl
xturtle.py, extended turtle graphics a new Tkinter based turtle graphics module for Python I just have released xturtle.py (v.0.91). It can be found at: http://sourceforge.net/tracker/?group_id=5470&atid=305470 with RequestID 1513695 (and 1513699 for the docs) and also here http://ada.rg16.asn

Re: [Python-Dev] ImportWarning flood

2006-06-28 Thread Martin v. Löwis
Ralf W. Grosse-Kunstleve wrote: > If there is a consenus, I'd create a new exception ImportErrorNoModule(name) > that is used consistently from all places. This would ensure uniformity of the > message in the future. A correction proposal should only be given if it is likely correct. There can be

Re: [Python-Dev] Is Lib/test/crashers/recursive_call.py really a crasher?

2006-06-28 Thread Armin Rigo
Hi Brett, On Tue, Jun 27, 2006 at 10:32:08AM -0700, Brett Cannon wrote: > OK, with you and Thomas both wanting to keep it I will let it be. I just > won't worry about fixing it myself during my interpreter hardening crusade. I agree with this too. If I remember correctly, you even mentioned in

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Fredrik Lundh
Guido van Rossum wrote: >> Is it unacceptable - or impractical - to break the addition of switch >> to python in two (minor version separated) steps ? > > But what's the point? We have until Python 3000 anyway. except that we may want to "reserve" the necessary keywords in 2.6... __

Re: [Python-Dev] School IIb?

2006-06-28 Thread Fredrik Lundh
Phillip J. Eby wrote: > Hear, hear! We already have if/elif, we don't need another way to spell > it. The whole point of switch is that it asserts that exactly *one* case > is supposed to match that's not true for all programming languages that has a switch construct, though; the common trait

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Fredrik Lundh
Nick Coghlan wrote: > There certainly isn't anything in the code above to suggest to a reader that > the condition attempting to guard evaluation of the switch statement might not > do its job. that's why the evaluation model used in the case statement needs to be explicit. that applies to the "

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Talin
Josiah Carlson wrote: > Talin <[EMAIL PROTECTED]> wrote: > >>My version of this is to add to Python the notion of a simple >>old-fashioned subroutine - that is, a function with no arguments and no >>additional scope, which can be referred to by name. For example: > > > I don't like the idea of

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Nick Coghlan
Guido van Rossum wrote: > I think we all agree > that side effects of case expressions is one way how we can deduce the > compiler's behind-the-scenes tricks (even School Ib is okay with > this). So I don't accept this as proof that Option 2 is better. OK, I worked out a side effect free example o

Re: [Python-Dev] PEP 3103: A Switch/Case Statement

2006-06-28 Thread Josiah Carlson
Talin <[EMAIL PROTECTED]> wrote: > My version of this is to add to Python the notion of a simple > old-fashioned subroutine - that is, a function with no arguments and no > additional scope, which can be referred to by name. For example: I don't like the idea of an embedded subrutine for a few

Re: [Python-Dev] PEP 328 and PEP 338, redux

2006-06-28 Thread Nick Coghlan
Guido van Rossum wrote: > However, I'm fine with setting *another* variable to the full package > name so someone who *really* wants to do relative imports here knows > the package name. OK, I'll do that. Any objections to __module_name__ as the name of the variable? (to keep things simple, run_mo