[issue23374] pydoc 3.x raises UnicodeEncodeError on sqlite3 package
Serhiy Storchaka
report at bugs.python.org
Mon Feb 2 16:21:25 CET 2015
Serhiy Storchaka added the comment:
There are few levels of this issue:
1) pydoc doesn't escape characters according to output encoding. It escapes characters uneencodable with sys.getfilesystemencoding(), but this encoding can differ from the encoding of sys.stdout or default encoding.
2) Default encoding for io.TestIOWrapper() and open() can be different from sys.getfilesystemencoding(). And it unexpectedly can be ASCII.
3) Mac OS doesn't support locales with the utf8 encoding (without hyphen).
Here is a patch which solves first level -- makes pydoc using appropriate encoding with the backslashreplace error handler.
----------
keywords: +patch
stage: -> patch review
type: crash -> behavior
versions: -Python 3.2, Python 3.3
Added file: http://bugs.python.org/file37981/pydoc_encoding.patch
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue23374>
_______________________________________
More information about the Python-bugs-list
mailing list