Ronald Oussoren <ronaldousso...@mac.com> added the comment: Using the CF API to fetch the system encoding won't work:
Using PyObjC: >>> CFStringConvertEncodingToIANACharSetName(CFStringGetSystemEncoding()) u'macintosh' There doesn't seem to be another way to extract the prefered encoding from the system. I see two possible resolutions for this issue: * Close as won't fix This is technically a platform issue that has been fixed in OSX 10.5 * Add a workaround that explicitly sets os.environ['LANG'] to 'en_US.UTF-8' before converting argument and environment values to Unicode (only on OSX < 10.4, when LANG=C and of course resetting the previous value after conversion) I have a 10.4 system I could develop this on, but that's currently in a different country than me. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue9167> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com