[issue14192] stdout.encoding not set when redirecting windows command line output

Martin v. Löwis report at bugs.python.org
Sun Mar 4 13:05:49 CET 2012

Martin v. Löwis <martin at v.loewis.de> added the comment:

That is impossible to implement. When outputting to a terminal window, the terminal's encoding is queried and used. When the Python script is run on its own, there may not even exist a terminal encoding.

In any case, this issue is resolved in Python 3 (not by setting the encoding to the terminal's encoding, but to the system code page). For 2.7, changing this would be a new feature, so I'm closing this as resolved - please upgrade to Python 3.

nosy: +loewis
resolution:  -> fixed
status: open -> closed

Python tracker <report at bugs.python.org>

More information about the Python-bugs-list mailing list