Luminescence v. 0.3 released

2010-12-17 Thread Pedro Matiello
Luminescence release 0.3 http://code.google.com/p/luminescence/ Luminescence is an application for generating HTML presentations from Markdown sources. It allows one to create simple presentations quickly. An small example

Re: If/then style question

2010-12-17 Thread Steven D'Aprano
On Thu, 16 Dec 2010 20:32:29 -0800, Carl Banks wrote: Even without the cleanup issue, sometimes you want to edit a function to affect all return values somehow. If you have a single exit point you just make the change there; if you have mulitple you have to hunt them down and change all of

Re: Newbie question about importing modules.

2010-12-17 Thread Tim Roberts
cronoklee cronok...@gmail.com wrote: I'm starting my first python project but I'm having trouble getting off the ground. I've read all I can find about relative and absolute import paths but it's just not making sense to me... There seems to be around ten different ways to import a script.

Re: Read / Write OpenOffice SpreadSheet ?

2010-12-17 Thread Torsten Mohr
Hello, There is no package needed to read or write the new open document files. The files are merely a jar archive containing XML files. You can open and update them using jar as a subprocess and manipulate the XML files using your favorite XML libraries DOM/SAX/XPath/Etree/etc. thanks for

Re: Newbie question about importing modules.

2010-12-17 Thread shearichard
On Dec 17, 4:42 pm, cronoklee cronok...@gmail.com wrote: Hi I'm starting my first python project but I'm having trouble getting off the ground. I've read all I can find about relative and absolute import paths but it's just not making sense to me... There seems to be around ten different

Re: If/then style question

2010-12-17 Thread Jean-Michel Pichavant
John Gordon wrote: (This is mostly a style question, and perhaps one that has already been discussed elsewhere. If so, a pointer to that discussion will be appreciated!) When I started learning Python, I wrote a lot of methods that looked like this: def myMethod(self, arg1, arg2): if

RE: If/then style question

2010-12-17 Thread Rob Richardson
-Original Message- What about, def myMethod(): for condition, exitCode in [ (cond1, 'error1'), (cond2, 'very bad error'), ]: if not condition: break else: do_some_usefull_stuff() # executed only if the we never hit the break

Re: If/then style question

2010-12-17 Thread Steven D'Aprano
On Fri, 17 Dec 2010 09:09:49 -0500, Rob Richardson wrote: First, just to clarify, I don't think the indentation I saw was what was originally posted. The else must be indented to match the if, and the two statements under else are in the else block. The return statement is indented at the

Re: If/then style question

2010-12-17 Thread Jean-Michel Pichavant
Rob Richardson wrote: -Original Message- What about, def myMethod(): for condition, exitCode in [ (cond1, 'error1'), (cond2, 'very bad error'), ]: if not condition: break else: do_some_usefull_stuff() # executed only if the

Re: If/then style question

2010-12-17 Thread David Robinow
On Thu, Dec 16, 2010 at 6:51 PM, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: ... Functions always have one entry. The only way to have multiple entry points is if the language allows you to GOTO into the middle of a function, and Python sensibly does not allow this. The one

Re: Newbie question about importing modules.

2010-12-17 Thread cronoklee
Hey thanks for the help fellas. The links were helpful and the pyExe program looks great. I might well end up using this. I'm still a little confused as to how the directory structure works. PIL (http://www.pythonware.com/products/pil/#pil117), for example comes packed in a folder called

Re: How to pop the interpreter's stack?

2010-12-17 Thread Robert Kern
On 12/16/10 6:33 PM, Steven D'Aprano wrote: On Thu, 16 Dec 2010 10:39:34 -0600, Robert Kern wrote: On 12/16/10 10:23 AM, Steven D'Aprano wrote: On Thu, 16 Dec 2010 07:29:25 -0800, Ethan Furman wrote: Tim Arnold wrote: Ethan Furmanet...@stoneleaf.us wrote in message

Re: Read / Write OpenOffice SpreadSheet ?

2010-12-17 Thread Stefan Behnel
Torsten Mohr, 17.12.2010 02:07: i search for a possibility to access OpenOffoce SpreadSheets from Python with a reasonably new version of Python. Can anybody point me to a package that can do this? Have you looked through the relevant PyPI packages?

Re: If/then style question

2010-12-17 Thread Steve Holden
On 12/17/2010 9:38 AM, Steven D'Aprano wrote: On Fri, 17 Dec 2010 09:09:49 -0500, Rob Richardson wrote: First, just to clarify, I don't think the indentation I saw was what was originally posted. The else must be indented to match the if, and the two statements under else are in the else

PyUNO [Was: Read / Write OpenOffice SpreadSheet ?]

2010-12-17 Thread Adam Tauno Williams
On Fri, 2010-12-17 at 10:19 +0100, Torsten Mohr wrote: Thanks, i read about it but as i understood it, UNO needs Python 2.3.x and i'd like to base on something actual. I do not *believe* this is true. http://pypi.python.org/pypi/cloudooo/1.0.9 for instance is Python 2.6 and uses PyUNO. I

RE: If/then style question

2010-12-17 Thread Rob Richardson
My thanks for pointing out the existence of the else: suite in the for statement. However, I remain confused. For reference, here's the original code: def myMethod(): for condition, exitCode in [ (cond1, 'error1'), (cond2, 'very bad error'), ]: if

Re: If/then style question

2010-12-17 Thread Tim Golden
On 17/12/2010 15:53, Steve Holden wrote: [... snip example of for-else ...] This construct appears to be unpopular in actual use, and when it comes up in classes and seminars there is always interesting debate as people discuss potential uses and realise there are useful applications. I use

ANN: Shed Skin 0.7

2010-12-17 Thread Mark Dufour
hi malcolm, Congratulations on your latest release! thanks! :D How well do python extension modules created with ShedSkin work with applications that expose a GUI, eg. Tkinter or wxPython apps? quite well I think, but there are some limitations you probably want to be aware of. these are

Re: If/then style question

2010-12-17 Thread Paul Rubin
Jean-Michel Pichavant jeanmic...@sequans.com writes: What about, def myMethod(): for condition, exitCode in [ (cond1, 'error1'), (cond2, 'very bad error'), ]: if not condition: break else: do_some_usefull_stuff() # executed only if

Re: PyUNO [Was: Read / Write OpenOffice SpreadSheet ?]

2010-12-17 Thread Stefan Behnel
Adam Tauno Williams, 17.12.2010 17:02: On Fri, 2010-12-17 at 10:19 +0100, Torsten Mohr wrote: Thanks, i read about it but as i understood it, UNO needs Python 2.3.x and i'd like to base on something actual. I do not *believe* this is true. http://pypi.python.org/pypi/cloudooo/1.0.9 for

Re: If/then style question

2010-12-17 Thread Ethan Furman
Rob Richardson wrote: My thanks for pointing out the existence of the else: suite in the for statement. However, I remain confused. For reference, here's the original code: def myMethod(): for condition, exitCode in [ (cond1, 'error1'), (cond2, 'very bad error'),

Re: If/then style question

2010-12-17 Thread Steve Holden
On 12/17/2010 11:13 AM, Tim Golden wrote: On 17/12/2010 15:53, Steve Holden wrote: [... snip example of for-else ...] This construct appears to be unpopular in actual use, and when it comes up in classes and seminars there is always interesting debate as people discuss potential uses and

Re: If/then style question

2010-12-17 Thread Mark Wooding
Steve Holden st...@holdenweb.com writes: I think the choice of keyword is probably not Guido's crowning language achievement, I remember the behaviour by considering a typical application: for thing in things: if shinyp(thing): break else: raise

Re: If/then style question

2010-12-17 Thread Arnaud Delobelle
Tim Golden m...@timgolden.me.uk writes: On 17/12/2010 15:53, Steve Holden wrote: [... snip example of for-else ...] This construct appears to be unpopular in actual use, and when it comes up in classes and seminars there is always interesting debate as people discuss potential uses and

Re: If/then style question

2010-12-17 Thread python
I now remember this idiom as the break else construct: either the loop breaks, or the else: suite is executed. A perfect description. Malcolm -- http://mail.python.org/mailman/listinfo/python-list

Re: If/then style question

2010-12-17 Thread Grant Edwards
On 2010-12-16, Stefan Sonnenberg-Carstens stefan.sonnenb...@pythonmeister.com wrote: The advantage in latter case is fewer operations, because you can skip the assignments, and it is more readable. The one entry, one exit is an advice. Not a law. Your code is OK. As long as it works ;-)

Re: If/then style question

2010-12-17 Thread Grant Edwards
On 2010-12-16, Steven D'Aprano steve+comp.lang.pyt...@pearwood.info wrote: On Thu, 16 Dec 2010 21:49:07 +, John Gordon wrote: (This is mostly a style question, and perhaps one that has already been discussed elsewhere. If so, a pointer to that discussion will be appreciated!) When I

RE: If/then style question

2010-12-17 Thread Rob Richardson
-Original Message- You have outlined what happens when cond1 and cond2 both evaluate to True -- what happens if, say, cond2 evaluates to False? - I reply And the light goes on! (And palm strikes forehead.) I was thinking that the error we were processing was raised

Re: PyUNO [Was: Read / Write OpenOffice SpreadSheet ?]

2010-12-17 Thread Tim Harig
On 2010-12-17, Adam Tauno Williams awill...@whitemice.org wrote: I would strongly recommend against floundering about in OOo's very complex XML files - it is trivially easy to render a document unusable. I do it all the time and have never had a problem. I don't generate the documents from

Re: PyUNO [Was: Read / Write OpenOffice SpreadSheet ?]

2010-12-17 Thread Stef Mientki
On 17-12-2010 17:02, Adam Tauno Williams wrote: On Fri, 2010-12-17 at 10:19 +0100, Torsten Mohr wrote: Thanks, i read about it but as i understood it, UNO needs Python 2.3.x and i'd like to base on something actual. I do not *believe* this is true. http://pypi.python.org/pypi/cloudooo/1.0.9

Re: If/then style question

2010-12-17 Thread Kev Dwyer
On Thu, 16 Dec 2010 21:49:07 +, John Gordon wrote: (This is mostly a style question, and perhaps one that has already been discussed elsewhere. If so, a pointer to that discussion will be appreciated!) When I started learning Python, I wrote a lot of methods that looked like this:

Re: Added Python, WSGI to XAMPP

2010-12-17 Thread Daniel Fetchinson
How-To: Add VirtualEnv and Pylons (WSGI framework) to XAMPP http://www.apachefriends.org/f/viewtopic.php?f=17t=42981 Maybe, if there's no Zope. Or we'll run away screaming... That is rather pathetically true... Ah well, each to their own... Chris What I really don't like right off is

Help with threading.local use in python-memcache module.

2010-12-17 Thread Sean Reifschneider
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Some time ago I accepted a patch to base the memcache client module on the threading.local class. Now I've got some reports of issues with this that I'm not sure what the best way to resolve is. Bug #530229:

Re: class inheritance

2010-12-17 Thread JLundell
On Saturday, March 13, 2010 9:03:36 AM UTC-8, Jonathan Lundell wrote: I've got a subclass of fractions.Fraction called Value; it's a mostly trivial class, except that it overrides __eq__ to mean 'nearly equal'. However, since Fraction's operations result in a Fraction, not a Value, I end up

subprocess.Popen() and a .msi installer

2010-12-17 Thread Sebastian Alonso
Hey everyone, I'm working on a script which uses subprocess to launch a bunch of installers, but I'm getting problems with .msi installers although .exe ones work fine. The output I get is this: import subprocess p = subprocess.Popen('python.msi') Traceback (most recent call last): File

Creating custom types from C code

2010-12-17 Thread Eric Frederich
Hello, I have an extension module for a 3rd party library in which I am wrapping some structures. My initial attempt worked okay on Windows but failed on Linux. I was doing it in two parts. The first part on the C side of things I was turning the entire structure into a char array. The second

Odd listcomp behaviour

2010-12-17 Thread Emile van Sebille
Does anyone else consider this a bug? Python 2.6.2 (r262:71600, Jun 16 2009, 11:09:39) [GCC 3.4.6 20060404 (Red Hat 3.4.6-10)] on linux2 Type help, copyright, credits or license for more information. ---1--- skippedords = '1,2,3,4,5' ['10%s' % ii for ii in skippedords.split(',')] ['101',

Re: Odd listcomp behaviour

2010-12-17 Thread Emile van Sebille
On 12/17/2010 3:08 PM Emile van Sebille said... Does anyone else consider this a bug? Hmmm... looks like it's split that I've got the issue with... this is a test.split() ['this', 'is', 'a', 'test'] this is a test.split(' ') ['this', 'is', 'a', 'test'] .split(' ') [''] .split() []

Re: Odd listcomp behaviour

2010-12-17 Thread Ethan Furman
Emile van Sebille wrote: Does anyone else consider this a bug? Python 2.6.2 (r262:71600, Jun 16 2009, 11:09:39) [GCC 3.4.6 20060404 (Red Hat 3.4.6-10)] on linux2 Type help, copyright, credits or license for more information. ---1--- skippedords = '1,2,3,4,5' ['10%s' % ii for ii in

Re: Odd listcomp behaviour

2010-12-17 Thread Emile van Sebille
On 12/17/2010 3:17 PM Emile van Sebille said... On 12/17/2010 3:08 PM Emile van Sebille said... Does anyone else consider this a bug? Hmmm... looks like it's split that I've got the issue with... Nevermind... if it's documented it's not a bug, right? Hrrmph. Emile str.split([sep[,

Re: subprocess.Popen() and a .msi installer

2010-12-17 Thread Benjamin Kaplan
On Fri, Dec 17, 2010 at 5:57 PM, Sebastian Alonso alon.sebast...@gmail.com wrote: Hey everyone, I'm working on a script which uses subprocess to launch a bunch of installers, but I'm getting problems with .msi installers although .exe ones work fine. The output I get is this: import

Re: Odd listcomp behaviour

2010-12-17 Thread MRAB
On 17/12/2010 23:08, Emile van Sebille wrote: Does anyone else consider this a bug? Python 2.6.2 (r262:71600, Jun 16 2009, 11:09:39) [GCC 3.4.6 20060404 (Red Hat 3.4.6-10)] on linux2 Type help, copyright, credits or license for more information. ---1--- skippedords = '1,2,3,4,5' ['10%s' %

Re: Read / Write OpenOffice SpreadSheet ?

2010-12-17 Thread Terry Reedy
On 12/17/2010 4:19 AM, Torsten Mohr wrote: Hello, There is no package needed to read or write the new open document files. The files are merely a jar archive containing XML files. You can open and update them using jar as a subprocess and manipulate the XML files using your favorite XML

Re: Read / Write OpenOffice SpreadSheet ?

2010-12-17 Thread Hans-Peter Jansen
On Friday 17 December 2010, 02:07:07 Torsten Mohr wrote: Hi, i search for a possibility to access OpenOffoce SpreadSheets from Python with a reasonably new version of Python. Can anybody point me to a package that can do this? http://ooopy.sourceforge.net/ Pete --

PySide: Python for Qt version 1.0.0~beta2 Mineshaft gap released

2010-12-17 Thread Matti Airas
The PySide team is happy to announce the second beta release of PySide: Python for Qt. New versions of some of the PySide toolchain components (API Extractor and Shiboken) have been released as well. This is a source code release only; we hope our community packagers will be providing provide

Re: If/then style question

2010-12-17 Thread Steven D'Aprano
On Fri, 17 Dec 2010 10:53:45 -0500, Steve Holden wrote about for...else: This construct appears to be unpopular in actual use, and when it comes up in classes and seminars there is always interesting debate as people discuss potential uses and realise there are useful applications. Yes, I

Re: If/then style question

2010-12-17 Thread Steven D'Aprano
On Fri, 17 Dec 2010 17:26:08 +, Grant Edwards wrote: Give me code that's easy-to-read and doesn't work rather code that works and can't be read any day. Well, in that case, you'll love my new operating system, written in 100% pure Python: [start code] print(this is an operating system)

Re: Creating custom types from C code

2010-12-17 Thread Stefan Behnel
Eric Frederich, 17.12.2010 23:58: I have an extension module for a 3rd party library in which I am wrapping some structures. My initial attempt worked okay on Windows but failed on Linux. I was doing it in two parts. The first part on the C side of things I was turning the entire structure into

[issue10254] unicodedata.normalize('NFC', s) regression

2010-12-17 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: Am 17.12.2010 01:56, schrieb STINNER Victor: STINNER Victor victor.stin...@haypocalc.com added the comment: Ooops, sorry. I just applied the patch suggested by Marc-Andre Lemburg in msg22885 (#1054943). As the patch worked for the

[issue10254] unicodedata.normalize('NFC', s) regression

2010-12-17 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: So lacking a new patch, I think we should revert the existing change for now. Oops, I missed that Alexander has proposed a patch. -- ___ Python tracker rep...@bugs.python.org

[issue10254] unicodedata.normalize('NFC', s) regression

2010-12-17 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: The logic suggested by Martin in msg120018 looks right to me, but the whole code seems to be unnecessarily complex. (And comb1==comb may need to be changed to comb1=comb.) I don't understand why linear search through skipped array is

[issue10254] unicodedata.normalize('NFC', s) regression

2010-12-17 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: Passing Part3 tests and not crashing on crash.py is probably good enough for a commit, but I don't have a proof that length 20 skipped buffer is always enough. I would agree with that. I still didn't have time to fully review the patch,

[issue10724] socket.close close telnet with RST

2010-12-17 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: but sometimes socket.close will send TCP RST to disconnect the telnet and with wrong sequence number This is called a a half-duplex TCP close sequence. Your application is probably closing the socket while there are still data in

[issue1195] Problems on Linux with Ctrl-D and Ctrl-C during raw_input

2010-12-17 Thread Finkregh
Changes by Finkregh finkr...@mafia-server.net: -- nosy: +Finkregh ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1195 ___ ___ Python-bugs-list

[issue10725] Better cache instrumentation

2010-12-17 Thread Raymond Hettinger
New submission from Raymond Hettinger rhettin...@users.sourceforge.net: Nick, can you look at this? -- assignee: ncoghlan components: Library (Lib) files: sized_cache.diff keywords: patch messages: 124194 nosy: ncoghlan, rhettinger priority: normal severity: normal status: open title:

[issue10716] Modernize pydoc to use CSS

2010-12-17 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: [Raymond] I'm looking for a deeper fix, all the in-line styling replaced by a stylesheet. Can you guys work together on bring this to fruition? When I talked about the CSS reset, I was referring to a precise part of the file proposed by Ron,

[issue10726] pydoc: don’t display raw reST in key word help

2010-12-17 Thread Éric Araujo
New submission from Éric Araujo mer...@netwok.org: When one runs “pydoc with”, the output is a block of text marked up with reST. It would be more helpful to render it as text or HTML thanks to a minimal reST parser and transformer. In

[issue2736] datetime needs an epoch method

2010-12-17 Thread Velko Ivanov
Velko Ivanov viva...@ivanov-nest.com added the comment: I'm very disappointed by the outcome of this discussion. You are committing the biggest sin of modern times - instead of promoting the obtaining and usage of knowledge to solve things, you place restrictions to force the dumbheads into

[issue1449496] Python should use 3GB Address Space on Windows

2010-12-17 Thread Martin Gfeller Martin Gfeller
Martin Gfeller Martin Gfeller g...@comit.ch added the comment: Martin, we're running with this for years and with many extensions modules, without an issue. What is 64-bit safe should be 32-bit safe, not only 31-bit safe. But you're right, this is not a proof, and we

[issue10724] socket.close close telnet with RST

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: The source used to create _socket.pyd is in Modules/socketmodule.c in the source code tarball available from the python web site. As neologix says, it is a thin wrapper around the OS level socket library. -- nosy:

[issue1449496] Python should use 3GB Address Space on Windows

2010-12-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: What is 64-bit safe should be 32-bit safe, not only 31-bit safe Not here. Python uses signed size_t for various lengths and sizes. On win32 this only gives you 31 bits... -- nosy: +amaury.forgeotdarc

[issue10726] pydoc: don’t display raw reST in key word help

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I'm not necessarily opposed to this, but an alternative is to modify pyspecific.py so that it generates text output from the ReST when it builds the pydoc topic index. -- components: +Demos and Tools nosy: +georg.brandl,

[issue10725] Better cache instrumentation

2010-12-17 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The _total_size thing looks like a wildly bad idea to me, since it's so poorly defined (and relying on a couple of special cases). Also, currsize is quite bizarre. Why not simply size? -- nosy: +pitrou

[issue2736] datetime needs an epoch method

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Alexander, I agree with Velko in that it isn't obvious to me how the addition of localtime would answer the desire expressed in this issue. It addresses Antoine's complaint about aware datetimes, but I don't see that it does anything

[issue2736] datetime needs an epoch method

2010-12-17 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Velko: on the other hand, given Victor's research, I don't see float seconds since an epoch appearing anywhere as a standard. Well, given that we already have fromtimestamp(), this sounds like a poor argument against a totimestamp() method (or

[issue10726] pydoc: don’t display raw reST in key word help

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: No need for any of that -- the output you see already is the text output from Sphinx. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10726

[issue10726] pydoc: don’t display raw reST in key word help

2010-12-17 Thread Georg Brandl
Changes by Georg Brandl ge...@python.org: -- resolution: - works for me status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10726 ___

[issue9011] ast_for_factor unary minus optimization changes AST

2010-12-17 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Yes, sorry; I'm not likely to find time to do anything with this. Unassigning, and downgrading priority. Is it worth leaving this open in case anyone wants to do something about it? -- assignee: mark.dickinson - priority: high -

[issue10726] pydoc: don’t display raw reST in key word help

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Well, in that case, can we change the text style for code and related markup to be something prettier? Normal single quotes, perhaps? -- ___ Python tracker rep...@bugs.python.org

[issue9011] ast_for_factor unary minus optimization changes AST

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Given the long projected lifetime of 2.7, I suppose it is. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9011 ___

[issue10726] pydoc: don’t display raw reST in key word help

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: s/prettier/more readable/ -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10726 ___ ___

[issue10726] pydoc: don’t display raw reST in key word help

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Sure, I can do that for the next version. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10726 ___

[issue10155] Add fixups for encoding problems to wsgiref

2010-12-17 Thread Phillip J. Eby
Phillip J. Eby p...@telecommunity.com added the comment: So, do you have any suggestions for a specific change to the patch? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10155 ___

[issue8754] ImportError: quote bad module name in message

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: The change would be fine with me. What happens with the PyUnicode_FromString() usage in the patch if the string cannot be decoded? That should not lead to a UnicodeError being raised. Also, the __main__ changes look gratuitous to me.

[issue10454] Clarify compileall command-line options

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: +1 -- Didn't read through all of the diff, but in general I trust you enough to believe that the new version is better than the old :) -- nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org

[issue10723] Undocumented built-in exceptions

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Basically fine, but the docs for indentation and tab error should document their inheritance more explicitly. -- nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org

[issue9234] argparse: aliases for positional arguments (subparsers)

2010-12-17 Thread Steven Bethard
Steven Bethard steven.beth...@gmail.com added the comment: The patch looks basically okay to me, though this line makes me nervous: dest += ' (%s)' % ', '.join(aliases) Since this is just for help formatting, can't you just modify metavar instead? The dest is the attribute on the namespace

[issue9234] argparse: aliases for positional arguments (subparsers)

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: I can see that this is really useful; approved for beta2 as soon as Steven's issue from the last message is handled. -- assignee: georg.brandl - bethard priority: normal - release blocker ___ Python

[issue10559] NameError in tutorial/interpreter

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Use that list doesn't make me happy, what about access? -- nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10559 ___

[issue10609] dbm documentation example doesn't work (iteritems())

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Why not replace it with an example that uses get() or setdefault() then? -- nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10609

[issue9938] Documentation for argparse interactive use

2010-12-17 Thread Steven Bethard
Steven Bethard steven.beth...@gmail.com added the comment: In the short term, just catch the SystemExit. In the slightly longer term, we could certainly provide a subclass, say, ErrorRaisingArgumentParser, that overrides .exit and .error to do nothing but raise an exception with the message

[issue8753] Py_ReprEnter and Py_ReprLeave are undocumented

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Yep, looks good, please commit. -- assignee: d...@python - eric.araujo nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8753

[issue9264] trace.py documentation is incomplete

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Yes, it's the new recommended style. (Please add to documenting/ when convenient :) -- nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9264

[issue10559] NameError in tutorial/interpreter

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Attached diff provides another suggested rewording that I think is clearer. -- nosy: +r.david.murray Added file: http://bugs.python.org/file20093/tut_argv.diff ___ Python tracker

[issue10559] NameError in tutorial/interpreter

2010-12-17 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: +1. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10559 ___ ___ Python-bugs-list mailing list

[issue10559] NameError in tutorial/interpreter

2010-12-17 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: Removed file: http://bugs.python.org/file20093/tut_argv.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10559 ___

[issue10559] NameError in tutorial/interpreter

2010-12-17 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: Added file: http://bugs.python.org/file20094/tut_argv.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10559 ___

[issue10559] NameError in tutorial/interpreter

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Committed in r87337. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10559

[issue2736] datetime needs an epoch method

2010-12-17 Thread Velko Ivanov
Velko Ivanov viva...@ivanov-nest.com added the comment: on the other hand, given Victor's research, I don't see float seconds since an epoch appearing anywhere as a standard. Where do you see this being used as a standard? Yes, I didn't mean standard as in RFCed and recommended and

[issue8154] os.execlp('true') crashes the interpreter on 2.x

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: OK, this went in to 2.7 without the OS conditional, and there has been no great hue and cry, so I guess it was safe enough :) As for the difference in error message between execlp and execlpe, I think that's fine. The execlpe index

[issue10454] Clarify compileall command-line options

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Committed in r87338. Backporting the relevant bits will be a bit of a pain, anyone who feels like doing it is welcome to. I may or may not get to it myself. -- resolution: - fixed stage: patch review - committed/rejected

[issue8753] Py_ReprEnter and Py_ReprLeave are undocumented

2010-12-17 Thread Daniel Stutzbach
Daniel Stutzbach stutzb...@google.com added the comment: Committed in r87339. Thanks everyone for the feedback! -- assignee: eric.araujo - stutzbach keywords: -needs review resolution: - accepted stage: patch review - committed/rejected status: open - closed versions: -Python 2.7

[issue10155] Add fixups for encoding problems to wsgiref

2010-12-17 Thread And Clover
And Clover a...@doxdesk.com added the comment: No, not specifically. My patch is conservative about what variables it recodes, yours more liberal, but it's difficult to say which is the better approach, or what PEP requires. If you're happy with the current patch, go ahead, let's have it

[issue2736] datetime needs an epoch method

2010-12-17 Thread Alexander Belopolsky
Alexander Belopolsky alexander.belopol...@gmail.com added the comment: On Fri, Dec 17, 2010 at 9:18 AM, R. David Murray rep...@bugs.python.org wrote: R. David Murray rdmur...@bitdance.com added the comment: Alexander, I agree with Velko in that it isn't obvious to me how the addition of

[issue2736] datetime needs an epoch method

2010-12-17 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: 1. Different application may need different epoch and retained precision depends on the choice of the epoch. But then why does fromtimestamp() exist? And returning a (seconds, microseconds) tuple does retain the precision. 2. The code above

[issue4188] Lib/threading.py causes infinite recursion when running as verbose

2010-12-17 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I can confirm that the patch fixes the recursion problem if threading._VERBOSE is set to true, but the test Antoine mentioned hangs when the test suite is run. _VERBOSE is an internal, undocumented facility, so perhaps the priority on

[issue10254] unicodedata.normalize('NFC', s) regression

2010-12-17 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: On Fri, Dec 17, 2010 at 3:47 AM, Martin v. Löwis rep...@bugs.python.org wrote: .. The worst case (wrt. cskipped) is the maximum number of characters that can get combined into a single base character. It used to be (and I

[issue10711] Rip out HTTP 0.9 client support

2010-12-17 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Patch committed in r87340. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10711

[issue4188] test_threading hang when running as verbose

2010-12-17 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Ok, I committed the patch in r87341 (3.2), r87342 (3.1) and r87343 (2.7). -- priority: high - normal stage: patch review - needs patch title: Lib/threading.py causes infinite recursion when running as verbose - test_threading hang when

[issue10725] Better cache instrumentation

2010-12-17 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Updated to use ABCs but still relies on user objects implementing __sizeof__. So it is accurate whenever sys.getsizeof() is accurate. -- Added file: http://bugs.python.org/file20095/sized_cache2.diff

  1   2   >