[issue34403] test_utf8_mode.test_cmd_line() fails on HP-UX due to false assumptions

STINNER Victor report at bugs.python.org
Tue Aug 28 03:40:22 EDT 2018


STINNER Victor <vstinner at redhat.com> added the comment:

Hi, I'm the author of the UTF-8 Mode PEP (PEP 540) and its implementation. I wrote test_utf8_mode. I wasn't sure that it was a good idea to hardcode the locale encoding depending on the platform. The fact that AIX and HP-UX use different locale encoding confirms that it was a bad choice. My PR 8967 gets the locale encoding at runtime instead of hardcoding it. It should fix the test on AIX and HP-UX.

To fix the test on HP-UX, I also removed the euro sign (U+20AC: €) from the test string. There is no need to test large code point: a single non-ASCII character is enough to validate the code.

Michael Osipov: would you mind to test my PR on HP-UX please?

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue34403>
_______________________________________


More information about the Python-bugs-list mailing list