Message104212
If a test fails, regrtest writes the backtrace to sys.stdout. If the backtrace contains a non-ASCII characters, it's encoded using sys.stdout encoding.
In some conditions, sys.stdout is unable to encode some or all non-ASCII characters. Eg. if there is no locale set (empty environment or at least empty LANG variable value), sys.stdout.encoding="ascii".
If regrtest fails to display a test output (error backtrace), regrtest exits directly (don't execute next tests).
I propose to use backslashreplace error handler in sys.stdout, as done for sys.stderr to avoid this annoying issue.
Attached patch (for py3k) replace sys.stdout by a new file using backslashreplace, just before executing the tests.
I don't know if the issue concerns also Python2. |
|
Date |
User |
Action |
Args |
2010-04-26 10:43:14 | vstinner | set | recipients:
+ vstinner |
2010-04-26 10:43:13 | vstinner | set | messageid: <1272278593.97.0.387479540648.issue8533@psf.upfronthosting.co.za> |
2010-04-26 10:43:12 | vstinner | link | issue8533 messages |
2010-04-26 10:43:11 | vstinner | create | |
|