Message6156

Author pjenvey
Recipients pekka.klarck, pjenvey
Date 2010-10-07.21:20:38
SpamBayes Score 1.0445372e-08
Marked as misclassified No
Message-id <1286486439.64.0.476461888048.issue1658@psf.upfronthosting.co.za>
In-reply-to
Content
So CPython has the 'mbcs' encoding as a generic name for the current Windows code page (CP_ACP) -- meaning mbcs could be one of many encodings depending on your locale. It also uses Windows system APIs for the encoding/decoding.

I'm not sure why it works this way -- maybe it's so CPython doesn't have to formally map all the various Windows encodings (including some of the odd Windows specific ones) to real encodings. Or maybe some of those encodings aren't supported on all Windows platforms.

The JVM's file.encoding property is derived from the current user's locale. The JVM maps the locale to one of its internal encodings. However it looks like it may fall back to UTF-8 in some cases.

So the JVM's file.encoding property could potentially be our filesystemencoding value on Windows. Would it be 100% reliable though?

And maybe we'd want to emulate the mbcs encoding for compatibility sake?
History
Date User Action Args
2010-10-07 21:20:39pjenveysetmessageid: <1286486439.64.0.476461888048.issue1658@psf.upfronthosting.co.za>
2010-10-07 21:20:39pjenveysetrecipients: + pjenvey, pekka.klarck
2010-10-07 21:20:39pjenveylinkissue1658 messages
2010-10-07 21:20:38pjenveycreate