[Python-3000] Fwd: UPDATED: PEP 3138- String representation in Python 3000
Atsuo Ishimoto
ishimoto at gembook.org
Sun Jun 1 11:05:17 CEST 2008
On Sun, Jun 1, 2008 at 5:15 PM, Oleg Broytmann <phd at phd.pp.ru> wrote:
>
> Filesystem encoding is koi8-r, terminal encoding is UTF-8, ls doesn't
> convert (because it doesn't know filesystem encoding) but simply replaces,
> like in Python filename.encode(LC_CTYPE, "replace"). No error reported.
>
Sorry for my bad wording. I wanted to say "ls doesn't reports error,
but silently prints '?'", not "ls converts filename as per terminal
encoding, without reporting conversion errors".
In my case, ls checks characters in the file name and convert invalid
characters to '?'.
[ishimoto at host test]$ export LANG=ja_JP.eucJP
[ishimoto at host test]$ ls
日本語
[ishimoto at host test]$ export LANG=C
[ishimoto at host test]$ ls
??????
More information about the Python-3000
mailing list