[issue4319] optparse and non-ascii help strings

2009-07-09 Thread Alexey Shamrin
Alexey Shamrin added the comment: There's nothing to fix here, I think... There's no point in allowing arbitrary byte strings in help strings. Especially because Python 3 features unicode strings by default. IMHO, this issue should be closed. And see also #2931 for remaining i18n problems with

[issue6455] Lib/distutils/tests/test_build_ext.py fails on windows

2009-07-09 Thread Hirokazu Yamamoto
New submission from Hirokazu Yamamoto : Extention name of shared object is ".pyd" not ".so" on windows. I hope attached patch will fix this issue. -- assignee: tarek components: Distutils, Windows files: fix_distutils_test.patch keywords: patch messages: 90376 nosy: ocean-city, tarek sev

[issue2751] Regression for executing packages

2009-07-09 Thread Rene Dudfield
Rene Dudfield added the comment: hello, thanks for the explanation of why it's that way. Any ideas of a work around? python2.5 has been out for ages now. Even if it was an accident, it's the behavior people expect, and it's still a regression. Also, why should it matter if a module is a p

[issue2931] optparse: various problems with unicode and gettext

2009-07-09 Thread Alexey Shamrin
Changes by Alexey Shamrin : -- versions: +Python 2.7 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue6453] Improve bool TypeError message

2009-07-09 Thread Terry J. Reedy
Terry J. Reedy added the comment: Phooey. I searched for 'bool TypeError' but it failed to return 6428. I will ask on py-dev why not. -- priority: normal -> resolution: duplicate -> stage: committed/rejected -> status: closed -> open ___ Python tr

[issue6393] OS X: python3 from python-3.1.dmg crashes at startup

2009-07-09 Thread Ned Deily
Ned Deily added the comment: Looks good and the "patched" patch also works in a py3k installer build. BTW, Mark, I was curious as to why you were unable to reproduce the problem with your own build. I should have mentioned that my testing was with complete installer (framework) builds. I su

[issue2751] Regression for executing packages

2009-07-09 Thread Nick Coghlan
Nick Coghlan added the comment: It doesn't work in 2.6 or 3.0 because, as stated above, it was only due to a bug that it even appeared to work at all in 2.5 (it was always meant to be disallowed because it puts dodgy data in the import machinery's internal records if you do it). It took a new f

[issue6443] _winreg.QueryValueEx confused on double null terminated strings

2009-07-09 Thread Andrew Ziem
Andrew Ziem added the comment: Well, I no longer need QueryValueEx because I found out win32file.MoveFileEx() does more easily what I need, but MoveFileEx (see attachment for working example) shows that the Microsoft Window API itself creates these "invalid values" -- Added file: http:/

[issue2751] Regression for executing packages

2009-07-09 Thread Rene Dudfield
Rene Dudfield added the comment: Hi, note -m on packages still works with python3.0 and python3.1. It works by allowing a __main__.py file that gets called by -m. This is a really annoying regression for python2.6. It's a fairly wide spread feature too. I can't see any PEP for why this regr

[issue6443] _winreg.QueryValueEx confused on double null terminated strings

2009-07-09 Thread Andrew Ziem
Andrew Ziem added the comment: Yes, regedit does remove the blanks, but this bug report is about QueryValueEx---not about SetValueEx :). There must be a way to read all the values compatible with Windows -- ___ Python tracker

[issue6447] PATCH: typo (English) in subprocess module

2009-07-09 Thread Lucas Prado Melo
New submission from Lucas Prado Melo : I am pretty sure this patch is alright. -- nosy: +lucaspmelo ___ Python tracker ___ ___ Python-b

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: On Thu, 09 Jul 2009 16:43:49 -0700, Vinay Sajip wrote: > Vinay Sajip added the comment: > >> However, sys.stdout|err can be assigned to some thing else >> (eg: py.test assigning it to an open file object) .. in which case it >> is legitimate to handle (cl

[issue6423] The cgi docs should advertize using "in" instead of "has_key"

2009-07-09 Thread Ezio Melotti
Changes by Ezio Melotti : -- priority: -> low ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pytho

[issue6454] Add "example" keyword argument to optparse constructor

2009-07-09 Thread Daniel Waylonis
Daniel Waylonis added the comment: Looking at the source, there's the undocumented "epilog" keyword, but it, unfortunately is automatically pushed through the formatter, which would not be desirable for the output. -- ___ Python tracker

[issue6435] logging: cache the traceback text on formatter, instead of record

2009-07-09 Thread Vinay Sajip
Vinay Sajip added the comment: [snip example of how to achieve same effect as recipe in a simpler way] >> How will this differ in its effect from your recipe? > Actually, I did not know about 'Filter' until now. I will give it a > try sometime. Wouldn't it improve your recipe further to use mo

[issue6454] Add "example" keyword argument to optparse constructor

2009-07-09 Thread Daniel Waylonis
New submission from Daniel Waylonis : It's useful to see and example or two detailing how a program should be invoked and the expected results. I'd like to add the "example" keyword which will be printed below the "options:" when the usage is displayed. It would not be formatted like the "de

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread Vinay Sajip
Vinay Sajip added the comment: > However, sys.stdout|err can be assigned to some thing else > (eg: py.test assigning it to an open file object) .. in which case it > is legitimate to handle (close) such objects (handles) by who > created it (py.test). @Sridhar: I disagree. Creation is not owne

[issue6323] Py3.1 pdb doesn't deal well with syntax errors

2009-07-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: Fixed in r73918 (py3k) and r73920 (release31-maint). Thanks for the report! -- resolution: -> fixed status: open -> closed ___ Python tracker __

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread Vinay Sajip
Changes by Vinay Sajip : -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/optio

[issue3518] multiprocessing: BaseManager.from_address documented but doesn't exist

2009-07-09 Thread Jesse Noller
Changes by Jesse Noller : -- resolution: fixed -> accepted status: closed -> open ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue6416] Failed to compile selectmodule.c on windows (trunk)

2009-07-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: PIPE_BUF was introduced for the subprocess module to use it... on posix platforms only. r73916 (trunk) and r73917 (py3k) add the suggested #ifdef, and also fix test_subprocess. -- nosy: +amaury.forgeotdarc resolution: -> fixed status: open -> c

[issue5862] multiprocessing 'using a remote manager' example errors and possible 'from_address' code leftover

2009-07-09 Thread Casey McGinty
Changes by Casey McGinty : -- nosy: +cmcginty ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue6323] Py3.1 pdb doesn't deal well with syntax errors

2009-07-09 Thread Andreas Kloeckner
Andreas Kloeckner added the comment: Vladislav: The behavior you find funny is actually correct. "pass" is a statement and as such not allowed in a lambda. (only expressions are) Your posting is unrelated to this bug report. If you're still confused, please ask on comp.lang.python. -- c

[issue3518] multiprocessing: BaseManager.from_address documented but doesn't exist

2009-07-09 Thread Casey McGinty
Casey McGinty added the comment: I would like to open this ticket back up. Python 2.6.2 docs still reference unimplemented 'from_address' method. http://docs.python.org/library/multiprocessing.html#multiprocessing.managers.BaseManager.from_address BaseManager.__reduce__ method also calls unim

[issue6323] Py3.1 pdb doesn't deal well with syntax errors

2009-07-09 Thread Vladislav
Vladislav added the comment: >>> lambda: pass SyntaxError: invalid syntax (, line 1) >>> lambda: pas at 0x00F5C858> >>> func_1=lambda: pas >>> func_1() Traceback (most recent call last): File "", line 1, in func_1() File "", line 1, in func_1=lambda: pas NameError: global name 'pa

[issue6443] _winreg.QueryValueEx confused on double null terminated strings

2009-07-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: Yes, but did you try to press "OK"? Regedit displays a warning that empty lines are not allowed, and *removes* them. -- ___ Python tracker __

[issue6453] Improve bool TypeError message

2009-07-09 Thread R. David Murray
R. David Murray added the comment: The error message is in error. Int is not allowed in 3.x, only bool. This is thus superseded by issue 6428, which has already been fixed. -- nosy: +r.david.murray priority: -> normal resolution: -> duplicate stage: -> committed/rejected status: op

[issue6453] Improve bool TypeError message

2009-07-09 Thread Terry J. Reedy
New submission from Terry J. Reedy : >>> cc=c() >>> bool(cc) Traceback (most recent call last): File "", line 1, in bool(cc) TypeError: __bool__ should return bool or int, returned int This is slightly jarring. Adding ' 0 or 1' after 'or int' would be nice (and trivial). Adding str(val) a

[issue6348] solaris/aix: Py_Initialize: can't initialize sys standard streams

2009-07-09 Thread nestor
nestor added the comment: Maybe make test will help troubleshoot this (BTW how do I enable verbose mode?): test test_ascii_formatd failed -- errors occurred; run in verbose mode for details test_cmath test test_cmath failed -- Traceback (most recent call last): File "/datawhse/test/data/expor

[issue4506] 3.0 make test failures on Solaris 10

2009-07-09 Thread R. David Murray
R. David Murray added the comment: NB: I fixed the test_posix failure on trunk/2.6/py3k/3.1 in r73908, r73914, r73913, and r73915. -- nosy: +r.david.murray ___ Python tracker ___

[issue6429] 2to3: fix_future conflicts with fix_print

2009-07-09 Thread R. David Murray
R. David Murray added the comment: See also issue 2412, which might or might not have a relevant patch. -- nosy: +r.david.murray ___ Python tracker ___ __

[issue6452] urllib2.Request() will not work with long authorization headers

2009-07-09 Thread Jamal Fanaian
New submission from Jamal Fanaian : While testing this bug report in Gwibber https://bugs.launchpad.net/gwibber/+bug/397297 I found that using urllib2.Request() with a long authorization would cause it to error and not authenticate. I'm not sure if it is because the header wasn't being passed or

[issue6451] 2to3 adds spare brackets to print

2009-07-09 Thread R. David Murray
R. David Murray added the comment: This is a duplicate of Issue6429. -- nosy: +r.david.murray priority: -> normal resolution: -> duplicate stage: -> committed/rejected status: open -> closed superseder: -> 2to3: fix_future conflicts with fix_print __

[issue6451] 2to3 adds spare brackets to print

2009-07-09 Thread Vasiliy
Changes by Vasiliy : -- title: 2to3 adds additional brackets to print -> 2to3 adds spare brackets to print ___ Python tracker ___ ___

[issue6451] 2to3 adds additional brackets to print

2009-07-09 Thread Vasiliy
Changes by Vasiliy : -- title: Additional brackets to print -> 2to3 adds additional brackets to print ___ Python tracker ___ ___ Python

[issue6451] Additional brackets to print

2009-07-09 Thread Vasiliy
New submission from Vasiliy : from __future__ import print_function print('Foo','Bar') print('FooBar') 2to3 translates it to print(('Foo','Bar')) print('FooBar') is it right? -- components: 2to3 (2.x to 3.0 conversion tool) files: test.py messages: 90349 nosy: bazooka

[issue6443] _winreg.QueryValueEx confused on double null terminated strings

2009-07-09 Thread Andrew Ziem
Andrew Ziem added the comment: Attached screenshot shows regedit handles \x00\x00 by showing all the "invalid values" (each \x00 becomes a line break). More importantly, Windows apparently reads all the "invalid value" when processing FileRenameOperations, so my Python program must be able to r

[issue6435] logging: cache the traceback text on formatter, instead of record

2009-07-09 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: > Vinay Sajip added the comment: > >> But the cache needs to be invalidated when `exc_info` is changed - >> as in set to None when it was a traceback object. > > When does the exc_info change for a record? AFAIK it's set when you > create a LogRecord, and t

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: > See my comments about your ConsoleHandler recipe(s) on issue6345 Correction: issue6435 -- ___ Python tracker ___

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: On Thu, 09 Jul 2009 06:48:28 -0700, Vinay Sajip wrote: > It should be understood that if a stream is passed to a StreamHandler, > the ownership of that stream is passed as well, so closing the handler > rather than the underlying stream is the right thin

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread holger krekel
holger krekel added the comment: To recap the use case: stdout is redirected during a test function run which might trigger arbitrary usage of logging-functionality. Not closing the temporary file would mean that there could be as many open files as there are test functions - or one needs to re

[issue6450] normpath() sometimes maps unicode to str

2009-07-09 Thread Martin v . Löwis
Martin v. Löwis added the comment: > Do the standard Python library functions that > operate on strings guarantee anything in general with respect to > conserving unicode? Can I make any assumption as to which codec was used > to encode the str returned from normpath? The bug tracker is not rea

[issue6450] normpath() sometimes maps unicode to str

2009-07-09 Thread Ezio Melotti
Changes by Ezio Melotti : -- components: +Unicode nosy: +ezio.melotti priority: -> normal stage: -> test needed versions: +Python 2.7 ___ Python tracker ___

[issue6449] Improve/update python.org/dev/

2009-07-09 Thread Brett Cannon
Brett Cannon added the comment: Technically pydot...@python.org is the proper place to report this stuff, but it's not a big deal as I unofficially in charge of /dev so I will take care of it. -- assignee: georg.brandl -> brett.cannon nosy: +brett.cannon _

[issue6450] normpath() sometimes maps unicode to str

2009-07-09 Thread Erik Sandberg
New submission from Erik Sandberg : On Linux, I get the following: >>> import os >>> os.path.normpath(u'/') '/' I would expect unicode to be mapped to unicode. os.path.abspath() has the same problem, see also issue 3426. This causes problems in my project, where a function requires its paramet

[issue6449] Improve/update python.org/dev/

2009-07-09 Thread Ezio Melotti
New submission from Ezio Melotti : Reading python.org/dev/ I noticed a few things that could be improved/updated: 1) in http://www.python.org/dev/implementations/ Unladen Swallow is missing; 2) in http://www.python.org/dev/contributing/ there's an "any and any" that should probably be "any and al

[issue2504] Add gettext.pgettext() and variants support

2009-07-09 Thread Martin v . Löwis
Martin v. Löwis added the comment: Only my lack of time prevents inclusion. -- ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue2504] Add gettext.pgettext() and variants support

2009-07-09 Thread David Schnur
David Schnur added the comment: I came across this ticket while looking for alternatives to Python's gettext, since I need msgctx support. It seems a patch was supplied for this a while back. I have never contributed to Python, and am not familiar with your release process, but is there anythi

[issue6416] Failed to compile selectmodule.c on windows (trunk)

2009-07-09 Thread R. David Murray
R. David Murray added the comment: I found this article that might be of interest with regards to PIPE_BUF (or rather lack thereof) on Windows: http://cygwin.com/ml/cygwin-patches/2004-q3/msg00084.html It doesn't look like "doing the right thing" in Windows where in Posix you would use PIPE_BU

[issue5753] CVE-2008-5983 python: untrusted python modules search path

2009-07-09 Thread Tomas Hoger
Tomas Hoger added the comment: Have you considered something like this? (patch against 3.1) --- Python/sysmodule.c.orig +++ Python/sysmodule.c @@ -1643,6 +1643,7 @@ PySys_SetArgv(int argc, wchar_t **argv) #endif /* Unix */ } #endif /* All others */ + if (n > 0 ||

[issue6416] Failed to compile selectmodule.c on windows (trunk)

2009-07-09 Thread R. David Murray
R. David Murray added the comment: This constant was introduced in r73818 by Gregory, so I'm assigning this ticket to him. Note that the trunk Windows buildbot is also failing to compile because of this bug. -- assignee: -> gregory.p.smith components: +Library (Lib) -Windows keywords:

[issue6377] distutils compiler switch ignored

2009-07-09 Thread Nicolas Dumazet
Nicolas Dumazet added the comment: It seems that the fix is still not perfect. At the moment ( r73906 ), if you try to build trunk using Python 2.6, you get: > python setup.py build running build running build_ext Traceback (most recent call last): File "setup.py", line 1901, in main()

[issue6414] struct module : processor endianness descriptions misleading

2009-07-09 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- assignee: georg.brandl -> rhettinger nosy: +rhettinger versions: +Python 3.2 -Python 2.5, Python 3.0 ___ Python tracker ___ _

[issue6448] imp.find_module() -- be explicity that 'path' must be a list

2009-07-09 Thread Jordan Bettis
New submission from Jordan Bettis : Hi. I just spent a while fighting with imp.find_module because I was trying to pass the path as a string, rather than a string embedded in a list: result = find_module('mod', '/path') rather than result = find_module('mod', ['/path']) The issue is compounde

[issue5191] Partial function application 'from the right'

2009-07-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: Closing as requested. -- nosy: +amaury.forgeotdarc resolution: -> rejected status: open -> closed ___ Python tracker ___

[issue816059] popen2 work, fixes bugs 768649 and 761888

2009-07-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: OTOH, the test code runs fine with python 2.4.4, so what is the purpose of this patch? -- nosy: +amaury.forgeotdarc ___ Python tracker _

[issue6447] PATCH: typo (English) in subprocess module

2009-07-09 Thread Yinon Ehrlich
Changes by Yinon Ehrlich : -- components: Library (Lib) files: subprocess.patch keywords: patch nosy: Yinon severity: normal status: open title: PATCH: typo (English) in subprocess module versions: Python 2.7 Added file: http://bugs.python.org/file14477/subprocess.patch

[issue5753] CVE-2008-5983 python: untrusted python modules search path

2009-07-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: Hello, > what's the current state of this issue? The proposed patch hasn't > still been projected into upstream Python code, so wondering: > 1, when and if it will be? I was hoping for more feedback before committing it. While it has been labeled a security

[issue5753] CVE-2008-5983 python: untrusted python modules search path

2009-07-09 Thread Jan Lieskovsky
Jan Lieskovsky added the comment: Hello guys, what's the current state of this issue? The proposed patch hasn't still been projected into upstream Python code, so wondering: 1, when and if it will be? 2, if you have found another solution / patch? Thanks && Regards, Jan. -- Jan iankko Liesko

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread Vinay Sajip
Vinay Sajip added the comment: > Is it a problem to have the logging module be a bit more defensive and > only try a flush/close if the stream isn't already closed? Not particularly, but it would be better if the following approach were taken: import logging import StringIO stream = StringIO.S

[issue6414] struct module : processor endianness descriptions misleading

2009-07-09 Thread Alexey Shamrin
Alexey Shamrin added the comment: Little style: "Native byte order is big-endian or little-endian, depending on the host system. For example, Intel x86 and AMD64 (x86-64) are little-endian; Motorola 68000 and PowerPC G5 are big-endian; ARM and DEC Alpha feature switchable endianness (bi-endian

[issue6414] struct module : processor endianness descriptions misleading

2009-07-09 Thread Alexey Shamrin
Alexey Shamrin added the comment: Good suggestions, Mark! We should do both, I think. I didn't know about sys.byteorder before your message ;-) Thanks for education! How about this: "Native byte order is big-endian or little-endian, depending on the host system. For example, Intel x86 and AMD

[issue6446] import_spam() in extending python can fail without setting the error.

2009-07-09 Thread Julian Andres Klode
New submission from Julian Andres Klode : The given example function initspam fails if an Based on some experience with my own code, I have found out that the function import_spam() fails when the module is not importable. In this case, it returns 0, although it should return -1 when an error o

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread holger krekel
holger krekel added the comment: I think the issue is unrelated to py.test - it just presents a use case as it wants to run 1000's of tests and capture stdout/stderr per each test function, cannot guess about a test's logging-usage yet wants to minimize memory/resource usage and close any tempor

[issue6393] OS X: python3 from python-3.1.dmg crashes at startup

2009-07-09 Thread Ronald Oussoren
Ronald Oussoren added the comment: Good catch, the code in the else is indeed in the wrong order. -- ___ Python tracker ___ ___ Python

[issue6333] logging: ValueError: I/O operation on closed file

2009-07-09 Thread Vinay Sajip
Vinay Sajip added the comment: > Shouldn't the logging module be reliable in such cases? It tries to be, but it's neither omnipotent nor omniscient. It doesn't expect streams which it's using to be closed out from under it. See my comments about your ConsoleHandler recipe(s) on issue6345. Sor

[issue6435] logging: cache the traceback text on formatter, instead of record

2009-07-09 Thread Vinay Sajip
Vinay Sajip added the comment: > But the cache needs to be invalidated when `exc_info` is changed - > as in set to None when it was a traceback object. When does the exc_info change for a record? AFAIK it's set when you create a LogRecord, and that's it. To be honest, I'm not sure why you nee

[issue6393] OS X: python3 from python-3.1.dmg crashes at startup

2009-07-09 Thread Mark Dickinson
Mark Dickinson added the comment: Thanks, Ronald! The patch fixes the problem for me. (I directly patched the locale.py file installed from the Python dmg, since I still haven't figured out how to build a python executable that exhibits this problem.) The patch doesn't look quite right, though

[issue6443] _winreg.QueryValueEx confused on double null terminated strings

2009-07-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: It seems that regedit itself cannot handle these values, see how users have to edit data in binary mode to enter empty strings: http://www.pcreview.co.uk/forums/thread-1715654.php Here is a script that shows the problem: the value is returned truncated be

[issue6445] Add check parameter to subprocess.Popen.communicate

2009-07-09 Thread OG7
New submission from OG7 : communicate is often used in one-liners, but becomes a four-liner if you want to check the process exit status. Adding a check parameter would make it more convenient to get things right and write non-buggy code. The CalledProcessError requires a cmd argument, which mea

[issue5870] subprocess.DEVNULL

2009-07-09 Thread OG7
Changes by OG7 : -- nosy: +OG7 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/op

[issue6443] _winreg.QueryValueEx confused on double null terminated strings

2009-07-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: The double null is supposed to mark the end of the whole sequence; the content you show under "PendingFileRenameOperations" is a invalid REG_MULTI_SZ value to me. How does regedit display it? -- nosy: +amaury.forgeotdarc _

[issue6377] distutils compiler switch ignored

2009-07-09 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: FWIW: I've changed our mxSetup code to use a method for accessing the compiler instance. Perhaps that's the better way to go for standard distutils commands as well ?! E.g. .get_compiler_object() -- ___ Python t

[issue6377] distutils compiler switch ignored

2009-07-09 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Tarek Ziadé wrote: > Tarek Ziadé added the comment: > > The build_ext command cannot be run twice, because the first time, the > "compiler" option may be set to "unix" for example, or left to None, and > then is transformed into a compiler object. That's t

[issue6393] OS X: python3 from python-3.1.dmg crashes at startup

2009-07-09 Thread Ronald Oussoren
Ronald Oussoren added the comment: The attached patch (issue6393-fix.patch) seems to fix the issue. Could you please test and have a look at the patch? It basicly tests if the output of nl_langinfo(CODESET) is the empty string and defaults to 'UTF-8' in that case (but only on OSX). I intent

[issue6377] distutils compiler switch ignored

2009-07-09 Thread Tarek Ziadé
Tarek Ziadé added the comment: The build_ext command cannot be run twice, because the first time, the "compiler" option may be set to "unix" for example, or left to None, and then is transformed into a compiler object. That's the bug. If you call it again, it'll break because the new_compiler()

[issue6393] OS X: python3 from python-3.1.dmg crashes at startup

2009-07-09 Thread Mark Dickinson
Mark Dickinson added the comment: > There is validity in saying that 'LANG=utf-8' is an invalid setting Agreed. But that doesn't really explain why e.g. LANG=en_US also produces "", while LANG=invalid produces "US-ASCII". > I do wonder how the user ended up with LANG=utf-8 in the first place

[issue6435] logging: cache the traceback text on formatter, instead of record

2009-07-09 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: > 2. The exception text needs to be stored in the record, because in some > instances (e.g. pickling and sending over a socket) this information > will not be available at the other end in any other way. Caching in the record object is thus the way to go. B

[issue6393] OS X: python3 from python-3.1.dmg crashes at startup

2009-07-09 Thread Ronald Oussoren
Ronald Oussoren added the comment: The manpage says that nl_langinfo returns an empty string when there is an invalid setting. There is validity in saying that 'LANG=utf-8' is an invalid setting, the LANG variable is supposed to a locale name, which would be a language setting (possibly comb

[issue6377] distutils compiler switch ignored

2009-07-09 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Tarek Ziadé wrote: > Tarek Ziadé added the comment: > > I'll set back the compiler attribute when compiler_obj is set too, > so third-party code will be able to work with it as before. > > The current code will deprecate this usage, by displaying a depre

[issue6393] OS X: python3 from python-3.1.dmg crashes at startup

2009-07-09 Thread Mark Dickinson
Mark Dickinson added the comment: > One *could* add a check in pythonrun.c to substitute some suitable > default (UTF-8) if nl_langinfo(CODESET) returns an empty value. While googling for the source of this problem, I found other software projects that take this approach. It doesn't seem tota

[issue6444] multiline exception logging via syslog handler

2009-07-09 Thread Max Arnold
New submission from Max Arnold : I use syslog message routing mechanism to log high-priority messages from my python code to separate file. When exceptions are logged, only first line routed to specified file, and the rest goes in /var/log/messages. Such problem exists when SyslogHandler instan

[issue6435] logging: cache the traceback text on formatter, instead of record

2009-07-09 Thread Vinay Sajip
Vinay Sajip added the comment: > Not thoroughly .. as I missed the point 1. on formatter processing > multiple records. But what do you say to points 2, 3 and 4? Of course they may not apply to your use case, but are they not valid points? -- ___

[issue6435] logging: cache the traceback text on formatter, instead of record

2009-07-09 Thread Sridhar Ratnakumar
Sridhar Ratnakumar added the comment: On Wed, 08 Jul 2009 23:59:17 -0700, Vinay Sajip wrote: > 1. The exception text cannot be cached in the formatter because a > formatter will format lots and lots of records. Formatters live for a > long time, records do not. Ah, yes. > Are you sure you'