[issue3067] setlocale fails with unicode strings on Py2 and with byte strings on Py3

2011-06-18 Thread Stefan Krah
Changes by Stefan Krah : -- nosy: +skrah ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/

[issue3067] setlocale fails with unicode strings on Py2 and with byte strings on Py3

2010-08-03 Thread Terry J. Reedy
Terry J. Reedy added the comment: The docs say that the locale arg should be None, tuple, or string, so I take that to mean that Unicode should be OK for 2.x, and that would help porting to 3.x. If bytes are rejected in 3.x, there should be TypeError raised, not ValueError, as is still the ca

[issue3067] setlocale fails with unicode strings on Py2 and with byte strings on Py3

2009-02-19 Thread Ezio Melotti
Ezio Melotti added the comment: FWIW the type("") is gone in Py3, now it is: "if locale and not isinstance(locale, _builtin_str):" where "from builtins import str as _builtin_str" (http://svn.python.org/view/python/branches/py3k/Lib/locale.py?view=markup) However Py3.0 now raises the same error