[Python-Dev] Removal of Win32 ANSI API

Antoine Pitrou solipsis at pitrou.net
Thu Nov 11 21:02:43 CET 2010


On Thu, 11 Nov 2010 20:44:52 +0100
"Martin v. Löwis" <martin at v.loewis.de> wrote:
> > How do you support cross-platform code using bytes filenames?
> > IIRC, it has already been argued that it was an important feature. Many
> > filesystem-related utilities might prefer to handle filenames in bytes
> > form.
> 
> It would be a policy decision. However, I think it is hear-say that
> filesystem-related utilities might prefer byte file names.

One possible situation is when you receive filenames in bytes form from
an external API or tool (or even the contents of a file). If you don't
know the encoding, keeping the bytes form is obviously recommended.

I don't know how often this happens.

Regards

Antoine.


More information about the Python-Dev mailing list