[docs] [issue3067] setlocale error message is confusing
report at bugs.python.org
Sat Nov 5 08:24:04 CET 2011
Petri Lehtinen <petri at digip.org> added the comment:
> If *locale* is specified, it may be a None, a string, or an iterable of two strings, language code and encoding. String pairs are converted to a single string using the locale aliasing engine.
What about the possible None value then? Do you think that mentions to
it be dropped?
I don't think so, because setlocale(locale.LC_ALL, None) is an
explicit way of saying "Return me the current value", especially
because the function's name is SETlocale, which doesn't make it
If None is not dropped, the ", language code and encoding" should
maybe be in parentheses insteead: "to strings (language code and
encoding), or None..."
Python tracker <report at bugs.python.org>
More information about the docs