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 vstinner
Recipients vstinner
Date 2011-02-11.13:04:08
SpamBayes Score 8.1332495e-05
Marked as misclassified No
Message-id <1297429451.12.0.801264472969.issue11187@psf.upfronthosting.co.za>
In-reply-to
Content
Since version 3.2, Python uses the locale encoding in PyUnicode_EncodeFSDefault() using _Py_wchar2char() and _Py_char2wchar() until the codec registry is initialized and the locale codec is loaded (until initfsencoding() is done).

Before Python 3.2, Python used ASCII in PyUnicode_AsEncodedString() at bootstrap  (before the codec registry was initialized): we don't need this hack anymore and it is bad to use ASCII instead of the locale encoding (encode/decode can fail).

This ticket is just a reminder for me: I am waiting Python 3.3 to remove PyUnicode_AsEncodedString() bootstrap hack ;-)
History
Date User Action Args
2011-02-11 13:04:11vstinnersetrecipients: + vstinner
2011-02-11 13:04:11vstinnersetmessageid: <1297429451.12.0.801264472969.issue11187@psf.upfronthosting.co.za>
2011-02-11 13:04:08vstinnerlinkissue11187 messages
2011-02-11 13:04:08vstinnercreate