[issue1443504] locale.getpreferredencoding() dies when setlocale fails

Jeroen Ruigrok van der Werven report at bugs.python.org
Fri May 1 22:04:31 CEST 2009


Jeroen Ruigrok van der Werven <asmodai at in-nomine.org> added the comment:

OK, then I'll apply it.

But I am curious about your thoughts about the _parse_localename()
method being called from setlocale() raising a ValueError, whereas a
setlocale(LC_CTYPE, "") should not fail at all, which it currently does
if the locale in the environment is not valid.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue1443504>
_______________________________________


More information about the Python-bugs-list mailing list