[Python-Dev] os.access and Unicode

Skip Montanaro skip at pobox.com
Tue Mar 8 20:29:48 CET 2005


    Brett> If there was no other way to get os.access-like functionality, I
    Brett> would say it should be backported.  But since there are other
    Brett> ways to figure out everything that os.access can tell you I say
    Brett> don't backport...

I don't think you can tell (certainly not easily) what the real user's
permissions are on a file without a lot of work.  access is almost never the
right tool for the job (most of the time euid == ruid), but when it is the
right tool it's a lot better than the alternative.

I say backport.  If people were trying to call os.access with unicode
filenames it would have been failing and they were either avoiding unicode
filenames as a result or working around it some other way.  I can't see how
making os.access work with unicode filenames is going to break existing
code.

Skip


More information about the Python-Dev mailing list