Message105676
Here is a patch catching the _PyUnicode_AsString() error.
input() uses sys.stdout.encoding to encode the prompt to a byte string, but
PyOS_StdioReadline() writes the prompt to stderr (it should use sys_stdout).
I don't know which encoding should be used if sys.stdout.encoding is None (eg.
if sys.stdout is a StringIO() object).
StringIO() of _io module has no encoding because it stores unicode characters,
not bytes. StringIO() of _pyio module is based on BytesIO() and use utf8
encoding, but the reference implementation is now _io. |
|
Date |
User |
Action |
Args |
2010-05-14 01:20:16 | vstinner | set | recipients:
+ vstinner, amaury.forgeotdarc, belopolsky, dangyogi, r.david.murray, gruszczy, flox |
2010-05-14 01:20:13 | vstinner | link | issue8256 messages |
2010-05-14 01:20:12 | vstinner | create | |
|