[issue3975] PyTraceBack_Print() doesn't respect # coding: xxx header
Amaury Forgeot d'Arc
report at bugs.python.org
Tue Oct 7 15:06:01 CEST 2008
Amaury Forgeot d'Arc <amauryfa at gmail.com> added the comment:
The patch goes in the good direction, here are some remarks:
- The two calls to open() are missing the O_BINARY flag, necessary on
Windows to avoid newline translation. This may be important for some codecs.
- the GIL should be released around calls to open(); searching the whole
sys.path can be long.
Besides this, the "char* filename" is relevant only on utf8-encoded
filesystems, and will not work on windows with non-ascii filenames. But
this is another issue.
Python tracker <report at bugs.python.org>
More information about the Python-bugs-list