Serhiy Storchaka
2015-10-08 06:51:28 UTC
New submission from Serhiy Storchaka:
The error handler of sys.stdout and sys.stdin is set to "surrogateescape" even for non-ASCII encoding.
$ LANG= PYTHONIOENCODING=UTF-8 ./python -c 'import sys; print(sys.stdout.encoding, sys.stdout.errors)'
UTF-8 surrogateescape
----------
components: IO
messages: 252515
nosy: haypo, ncoghlan, serhiy.storchaka
priority: normal
severity: normal
status: open
title: sys.stdout.errors is set to "surrogateescape"
type: behavior
versions: Python 3.5, Python 3.6
_______________________________________
Python tracker <***@bugs.python.org>
<http://bugs.python.org/issue25339>
_______________________________________
The error handler of sys.stdout and sys.stdin is set to "surrogateescape" even for non-ASCII encoding.
$ LANG= PYTHONIOENCODING=UTF-8 ./python -c 'import sys; print(sys.stdout.encoding, sys.stdout.errors)'
UTF-8 surrogateescape
----------
components: IO
messages: 252515
nosy: haypo, ncoghlan, serhiy.storchaka
priority: normal
severity: normal
status: open
title: sys.stdout.errors is set to "surrogateescape"
type: behavior
versions: Python 3.5, Python 3.6
_______________________________________
Python tracker <***@bugs.python.org>
<http://bugs.python.org/issue25339>
_______________________________________