[issue7085] strptime problem

2009-10-08 Thread Brett Cannon
Brett Cannon added the comment: It's confirmed on 2.5 - trunk, but it is not an issue in at least 3.1 and py3k. As Ned pointed out, time imports _strptime.py from the standard library which is known to be a no-no. But still, it's odd that it crashed on Snow Leopard but not Leopard. I will le

[issue7085] strptime problem

2009-10-08 Thread Jiri Krivanek
Jiri Krivanek added the comment: The suggested workaround helped to solve the issue to me. Thank for it very much. I am using Python 2.4.4 and cannot upgrade to anything above 2.4 due to incompatibility between .pyc files (I have tenths of production sites with Python 2.4.4, with automatic u

[issue7085] strptime problem

2009-10-08 Thread Ned Deily
Ned Deily added the comment: It fails for me as well on 10.6 (Intel) with 2.6 and trunk and did not fail on 10.5 (ppc). time.strptime does an import of a python module from C code so, not surprisingly, adding a time.strptime call in the main module prior to the thread.start_new_thread avoids

[issue7088] New (in 2.6) functions in signal module are not documented as unix-only

2009-10-08 Thread Daniel Stutzbach
New submission from Daniel Stutzbach : 2.6 introduced several new functions to the signal module that are not available on Windows (setitimer, getitimer, and siginterrupt). However, they aren't documented with Availability: Unix. -- assignee: georg.brandl components: Documentation messa

[issue7087] use keyword 'as' in _xmlplus

2009-10-08 Thread Benjamin Peterson
Benjamin Peterson added the comment: _xmlplus is not part of Python. Please report this bug to the PyXML maintainers. -- nosy: +benjamin.peterson resolution: -> invalid status: open -> closed ___ Python tracker __

[issue7087] use keyword 'as' in _xmlplus

2009-10-08 Thread s7v7nislands
New submission from s7v7nislands : In these files: _xmlplus/xpath/ParsedAbbreviatedAbsoluteLocationPath.py _xmlplus/xpath/ParsedAbbreviatedRelativeLocationPath.py, use the keyword 'as'. -- messages: 93770 nosy: s7v7nislands severity: normal status: open title: use keyword 'as' in _xmlplu

[issue7069] inspect.isabstract to return boolean values only

2009-10-08 Thread Gabriel Genellina
Gabriel Genellina added the comment: I don't think we should test the actual type returned (bool); that would be overspecifying. The documentation doesn't promise it IS a boolean, and no other test for any isXXX() function checks the type either. I'd remove the last five assertions.

[issue7086] logging.handlers.SysLogHandler with TCP support

2009-10-08 Thread Jr Aquino
Changes by Jr Aquino : Removed file: http://bugs.python.org/file15084/handlers.py.diff ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue7086] logging.handlers.SysLogHandler with TCP support

2009-10-08 Thread Jr Aquino
Jr Aquino added the comment: Here is the patch with the requested syntactical corrections. -- Added file: http://bugs.python.org/file15085/handlers.py.diff ___ Python tracker ___

[issue7086] logging.handlers.SysLogHandler with TCP support

2009-10-08 Thread R. David Murray
R. David Murray added the comment: I'll leave it to Vinay to pronounce on the request and the validity of the patch, but a couple of comments on the mechanics of the patch: You have some rogue whitespace on one of the blank lines. More importantly, you are adding a keyword parameter at the beg

[issue7086] logging.handlers.SysLogHandler with TCP support

2009-10-08 Thread Jr Aquino
New submission from Jr Aquino : This patch is to address the deficiency in sending syslog messages to an external syslog server via tcp or udp. Currently the handler only really supports udp unless it is being redirected locally through a unix socket. The submitted patch allows for the standa

[issue7085] strptime problem

2009-10-08 Thread Jiri Krivanek
New submission from Jiri Krivanek : The following simple code works perfectly on W2K, WXP, Ubuntu, OSX10.4 OSX10.5. It, however, stopped working on OSX10.6 (Snow Leopard): It simply crashes. It is a strptime() which causes problems to me. Any idea? Any workaround? import time import thread d

[issue7071] distutils and IronPython compatibility

2009-10-08 Thread Brian Curtin
Changes by Brian Curtin : -- nosy: +briancurtin ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue7084] printing a list releases the GIL carelessly

2009-10-08 Thread Antoine Pitrou
New submission from Antoine Pitrou : Function list_print() in listobject.c releases the GIL before calling fprintf() but doesn't check the list size again when it gets the GIL back. If another thread truncated the list, a crash can ensue. The attached script crashes reliably here. -- fil

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Mark Dickinson
Changes by Mark Dickinson : -- versions: -Python 2.7, Python 3.1, Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: Thanks Georg and Eric for the feedback! New wording committed in r75289 (trunk), r75290 (py3k), r75291 (release31-maint). Leaving open for the backport to release26-maint. BTW, it's much easier to describe the rules in Python than in prose: def strip_zero_d

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread R. David Murray
R. David Murray added the comment: I think the 'as if with' is probably valid English, but if you want to make it sound better yet retain the same level of pedantry you could instead say, e.g.: "in the same way as presentation type e using precision p-1". -- nosy: +r.david.murray priori

[issue7083] locals() behaviour differs when tracing is in effect

2009-10-08 Thread André Bjärby
Changes by André Bjärby : -- components: +Extension Modules, Interpreter Core -Documentation nosy: -andbj versions: +Python 2.4, Python 2.5 -Python 2.7, Python 3.2 ___ Python tracker ___

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: Okay. I'll replace the 'as if with' with simply 'with'. That doesn't quite meet my favoured level of pedantry any more, but it does read better and it's not going to lead to any confusion. :) -- ___ Python track

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Georg Brandl
Georg Brandl added the comment: The "as if with" feels strange, otherwise it is fine with me. -- nosy: +georg.brandl ___ Python tracker ___ __

[issue7082] Patch for get_filename in email.message when content-disposition is missing

2009-10-08 Thread R. David Murray
Changes by R. David Murray : -- stage: patch review -> commit review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue7082] Patch for get_filename in email.message when content-disposition is missing

2009-10-08 Thread R. David Murray
R. David Murray added the comment: 2.4 and 2.5 are open only for security patches, which this is not, so I've removed them from versions, and added 3.1 and 3.2, which have the same code. The patch looks appropriate to me, and is what the original bug report requested. Note that the Content-Typ

[issue7083] locals() behaviour differs when tracing is in effect

2009-10-08 Thread Terry J. Reedy
Terry J. Reedy added the comment: I think the doc is clear enough if one reads and believes it. The main doc is "Update and return a dictionary representing the current local symbol table." That pretty clearly says that subsequent changes to the local symbol table may make the dict out of date

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Eric Smith
Eric Smith added the comment: I obviously hadn't thought of those cases, either. This version looks good(er) to me. -- ___ Python tracker ___

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: Thanks, Eric. I noticed that the description was missing details of what happens to trailing zeros (i.e., they're removed) and what happens to special values: infinities, zeros, nans. Here's the revised revised text: General format. For a given precision `

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Eric Smith
Eric Smith added the comment: That wording is okay with me. Maybe run it by Georg to see if he has any suggestions? Or just check it in and see if anyone complains. But I'm okay with it as-is. Thanks for doing this. Eric. -- ___ Python tracker

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: Proposed revision: General format. For a given precision ``p >= 1``, this rounds the number to ``p`` significant digits and then formats the result in either fixed-point format or in scientific notation, depending on its magnitude. The precise rules are a

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: Ah. Found them. http://docs.python.org/library/string.html#formatspec -- ___ Python tracker ___ __

[issue7083] locals() behaviour differs when tracing is in effect

2009-10-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- assignee: -> georg.brandl components: +Documentation -Extension Modules, Interpreter Core nosy: +georg.brandl versions: +Python 2.7, Python 3.2 -Python 2.4, Python 2.5 ___ Python tracker

[issue7051] 'g'/'G' format docs need a little more explanation

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: Benjamin, which docs are you looking at here? The ones at: http://docs.python.org/library/stdtypes.html#string-formatting-operations say: """Floating point format. Uses lowercase exponential format if exponent is less than -4 or not less than precision, dec

[issue7083] locals() behaviour differs when tracing is in effect

2009-10-08 Thread André Bjärby
André Bjärby added the comment: It's documented that "The contents of this dictionary should not be modified; changes may not affect the values of local variables used by the interpreter." The script does the opposite. Perhaps an addition to the documentation? "The contents of this dictionary m

[issue7083] locals() behaviour differs when tracing is in effect

2009-10-08 Thread Guido van Rossum
Guido van Rossum added the comment: So there's no bug here right? It's even documented. -- nosy: +gvanrossum resolution: -> rejected status: open -> closed ___ Python tracker __

[issue6845] Restart support in binary upload for ftplib

2009-10-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- components: +Library (Lib) -None priority: -> normal stage: -> patch review versions: +Python 3.2 ___ Python tracker ___ _

[issue6845] Restart support in binary upload for ftplib

2009-10-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +pitrou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue7048] decimal.py: logb: round the result if it is greater than prec

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: I've updated to the newest version of the test-suite in r75285 through r75287. As before, r75285 needs to be backported to the 2.6 maintenance branch once its unfrozen. I'm currently skipping those two scaleb tests, until we work out what should be going on

[issue6845] Restart support in binary upload for ftplib

2009-10-08 Thread Pablo Mouzo
Changes by Pablo Mouzo : -- nosy: +gregory.p.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.p

[issue7078] struct help in the interpreter does not explain about the fmt option

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: Thanks for the patch, Gabriel! Applied to trunk in r75283. (I also fixed the indentation for the list of order/size/alignment specifiers.) Merged to py3k in r75284, release31-maint in r75285. Leaving open for the merge to release26-maint. -- assign

[issue7083] locals() behaviour differs when tracing is in effect

2009-10-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: The same is thing is true of the frame's f_locals attribute. This attribute is a copy of the local variables in the frame, because the internal storage of these variables is a raw C array for faster access. This copy is only synchronized back when a tracing func

[issue6962] traceback.format_exception_only does not return SyntaxError carot correctly

2009-10-08 Thread Ezio Melotti
Changes by Ezio Melotti : -- resolution: duplicate -> ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://ma

[issue5511] zipfile - add __exit__ attribute to make ZipFile object compatible with with_statement

2009-10-08 Thread Brian Curtin
Brian Curtin added the comment: Added two tests -- test_close and test_close_on_exception, which check if fp is None after __exit__ from a normal and exception case. -- keywords: +patch Added file: http://bugs.python.org/file15082/issue5511_complete_20091008.patch _

[issue7082] Patch for get_filename in email.message when content-disposition is missing

2009-10-08 Thread Darren Worrall
Changes by Darren Worrall : -- title: Patch for get attachments in email -> Patch for get_filename in email.message when content-disposition is missing ___ Python tracker ___ ___

[issue7083] locals() behaviour differs when tracing is in effect

2009-10-08 Thread André Bjärby
New submission from André Bjärby : Running the attached script shows that locals() behaves differently depending on whether sys.settrace() is active. This does not occur when calling locals() in the global scope, only when used inside functions. -- components: Extension Modules, Interpr

[issue7082] Patch for get attachments in email

2009-10-08 Thread Darren Worrall
Changes by Darren Worrall : -- nosy: +barry versions: +Python 2.4, Python 2.5, Python 2.6 ___ Python tracker ___ ___ Python-bugs-list m

[issue7082] Patch for get attachments in email

2009-10-08 Thread Darren Worrall
Darren Worrall added the comment: Patch is against 2.7 trunk, but should backport without any resistance. -- keywords: +patch Added file: http://bugs.python.org/file15080/message-getfilename.patch ___ Python tracker

[issue7082] Patch for get attachments in email

2009-10-08 Thread Darren Worrall
New submission from Darren Worrall : Finger spasm submitted this without a comment, apologies. I believe the fix applied in http://bugs.python.org/issue1403349 is not actually correct. In the case where Content-Disposition is missing, the 'name' parameter should be on Content-Type - but the orig

[issue7082] Patch for get attachments in email

2009-10-08 Thread Darren Worrall
Changes by Darren Worrall : -- nosy: DazWorrall severity: normal status: open title: Patch for get attachments in email versions: Python 2.7 ___ Python tracker ___ ___

[issue6902] Built-in types format incorrectly with 0 padding.

2009-10-08 Thread Nick Coghlan
Nick Coghlan added the comment: Note that the 2.6 branch didn't seem to suffer this problem when I checked it earlier tonight. -- nosy: +ncoghlan ___ Python tracker ___ _

[issue7081] ">" formatting behaving like "=" formatting

2009-10-08 Thread Nick Coghlan
Nick Coghlan added the comment: Just checked, and yep, it's a duplicate of 6902 - the problem does indeed go away if I use a different formatting character. -- resolution: -> duplicate status: open -> closed superseder: -> Built-in types format incorrectly with 0 padding. ___

[issue7081] ">" formatting behaving like "=" formatting

2009-10-08 Thread Eric Smith
Eric Smith added the comment: I think they're the same issue, relating to what happens if there's an alignment specifier supplied along with '0'. I'm planning on working on this issue this weekend and I'll verify if it's the same problem. -- ___ Pyth

[issue7081] ">" formatting behaving like "=" formatting

2009-10-08 Thread Mark Dickinson
Mark Dickinson added the comment: Is this the same problem as in issue 6902? -- nosy: +mark.dickinson ___ Python tracker ___ ___ Pytho

[issue7081] ">" formatting behaving like "=" formatting

2009-10-08 Thread Nick Coghlan
New submission from Nick Coghlan : The ">" alignment flag to format() is not right aligning numbers properly on trunk and the py3k branch: >>> format(0x1234, "+#08x") '+0x01234' >>> format(0x1234, "0=+#8x") '+0x01234' >>> format(0x1234, "0>+#8x") '+0x01234' That last one should be: >>> format(0

[issue6280] calendar.timegm() belongs in time module, next to time.gmtime()

2009-10-08 Thread Anh Hai Trinh
Changes by Anh Hai Trinh : -- nosy: +aht versions: +Python 2.6 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: h

[issue7077] SysLogHandler can't handle Unicode

2009-10-08 Thread Vinay Sajip
Vinay Sajip added the comment: > Robert Szefler added the comment: > > Fine with me, though problems would arise. Default encoding for example. > If encoding selection is mandatory it would break compatibility. Using > default locale is not such a good idea - local machine's locale would > ge

[issue4064] distutils.util.get_platform() is wrong for universal builds on macosx

2009-10-08 Thread Ronald Oussoren
Ronald Oussoren added the comment: Michael: please file a new issue for this, your problem seems to be unrelated to this one. In that issue include information about: 1) The python version you are using 2) The version of MacOSX 3) The version of Xcode (open /Developer/Applications/Xcode.app,

[issue5511] zipfile - add __exit__ attribute to make ZipFile object compatible with with_statement

2009-10-08 Thread Ezio Melotti
Changes by Ezio Melotti : -- keywords: -needs review, patch ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue4064] distutils.util.get_platform() is wrong for universal builds on macosx

2009-10-08 Thread Michael Wise
Michael Wise added the comment: While the discussion seems to think the matter is closed, I wanted to install numpy 1.30 which requires Python 2.6 and all my machines are PPC (G4 or G5 - nice architectures). gcc-4.0 -arch ppc -arch i386 -fno-strict-aliasing ... followed, unsurprisingly, by: g

[issue7077] SysLogHandler can't handle Unicode

2009-10-08 Thread Robert Szefler
Robert Szefler added the comment: Fine with me, though problems would arise. Default encoding for example. If encoding selection is mandatory it would break compatibility. Using default locale is not such a good idea - local machine's locale would generally not need to have any correlation to th

[issue7079] file_close() ignores return value of close_the_file

2009-10-08 Thread Gregory P. Smith
Changes by Gregory P. Smith : -- assignee: -> gregory.p.smith priority: -> high ___ Python tracker ___ ___ Python-bugs-list mailing l