This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ncoghlan
Recipients akuchling, georg.brandl, jlgijsbers, lemburg, loewis, meonkeys, mhammond, ncoghlan, syvere, tim.peters
Date 2017-05-09.09:49:54
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1494323394.59.0.967012238323.issue504219@psf.upfronthosting.co.za>
In-reply-to
Content
Trying to come up with a short LC_MONETARY example for PEP 538, I just ran into what seems to be a related problem with locale.resetlocale(), which is that it doesn't work properly for categories other than LC_CTYPE: locale.getdefaultlocale() doesn't let you say which category you're actually interested in, so even if you specific a category for resetlocale(), it's going to look at the LC_CTYPE setting, *NOT* the one for the category you're interested in.


So perhaps a suitable design change here would be to update resetlocale() to just pass an empty string (letting the underlying platform API call figure out the right default), rather than passing the result of locale.getdefaultlocale()?
History
Date User Action Args
2017-05-09 09:49:54ncoghlansetrecipients: + ncoghlan, lemburg, tim.peters, loewis, mhammond, akuchling, georg.brandl, jlgijsbers, syvere, meonkeys
2017-05-09 09:49:54ncoghlansetmessageid: <1494323394.59.0.967012238323.issue504219@psf.upfronthosting.co.za>
2017-05-09 09:49:54ncoghlanlinkissue504219 messages
2017-05-09 09:49:54ncoghlancreate