[Pythonmac-SIG] Opening files with Japanese characters on Tiger
Henning Hraban Ramm
hraban at fiee.net
Sat Dec 8 00:39:54 CET 2007
Am 2007-12-07 um 17:26 schrieb James Kelly:
> I ran into an issue recently opening files with Japanese characters on
> Tiger. Essentially I am reading from a utf-8 file containing lists
> of file
> names. Most are completely in English, a few contain Japanese
> characters in
> the filename. I am opening the files for a binary write.
> Unfortunately
> when I do this, and the filename contains Japanese characters, I
> get an
> exception of type exceptions.IOError, with the specific exception
> being an
> 'invalid mode: wb.'
Don't know if this could be the reason, but did you take OSX's
decomposed Unicode in the filesystem into account?
I often struggle with that stuff.
Maybe there's a difference between 10.4 and 10.5, I don't know.
Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net
https://www.cacert.org (I'm an assurer)
More information about the Pythonmac-SIG
mailing list