[Python-Dev] PEP 383 update: utf8b is now the error handler

Michael Urman murman at gmail.com
Sun May 3 17:35:16 CEST 2009


On Sun, May 3, 2009 at 08:43, Antoine Pitrou <solipsis at pitrou.net> wrote:
> Also, if utf8-b is not provided as a codec, will there be an easy way for user
> code to use the same encoding as the IO layer does? (e.g.
> os.fsdecode/os.fsencode)?

I like the idea of fsencode/fsdecode functions, but we need to be
careful deciding what they accept and produce on Windows. I'd expect
them to be identity functions, but then the difference in platform
behavior suggests perhaps they should be in os.path.

Unicode to Unicode on Windows would further mean fsencode wouldn't be
useful for sending filenames over sockets, and "utf8" will be prone to
exceptions on the very names we're trying to support right now. Is
there an advantage to not providing the the "utf8b" behavior as a
registered codec?

-- 
Michael Urman


More information about the Python-Dev mailing list