Serhiy Storchaka added the comment: Before importing the io module sys.stderr is stdprinter. It always encodes written string to UTF-8. Proposed patch makes it to use the backslashreplace error handler.
In future perhaps we could implement stdprinter in Python. ---------- components: +Interpreter Core keywords: +patch stage: -> patch review Added file: http://bugs.python.org/file40625/stdprinter_backslashreplace.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue25182> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com