Author giampaolo.rodola
Recipients Deniz Bozyigit, eryksun, gary ruben, giampaolo.rodola, paul.moore, r.david.murray, steve.dower, tim.golden, zach.ware
Date 2019-02-17.11:51:01
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1550404261.96.0.889291213469.issue33935@roundup.psfhosted.org>
In-reply-to
Content
@eryksun

> Using the VSN and file index as if they're the same as POSIX st_dev and st_ino is technically wrong. There is no guarantee that this tuple uniquely identifies a file in Windows.

I agree. FWIW, I faced the same issue on pyftpdlib and ended up not supporting Windows: 
https://github.com/giampaolo/pyftpdlib/blob/eef8a5650cd611da1df5fce16974ce90f43f4dc0/pyftpdlib/filesystems.py#L596-L605
It seems to me the problem here is os.path.samefile():
 https://github.com/python/cpython/blob/0185f34ddcf07b78feb6ac666fbfd4615d26b028/Lib/genericpath.py#L87-L98

@steve.dower
> For Windows it would be best (though slower) to pass the paths through os._getfinalpathname before comparison.

It seems this is how samefile() was originally implemented but it was changed:
https://github.com/python/cpython/commit/490b32a3976d84eaf1d6ca8cdcb00eac0ce5055b
https://bugs.python.org/issue11939
History
Date User Action Args
2019-02-17 11:51:01giampaolo.rodolasetrecipients: + giampaolo.rodola, paul.moore, tim.golden, r.david.murray, zach.ware, eryksun, steve.dower, Deniz Bozyigit, gary ruben
2019-02-17 11:51:01giampaolo.rodolasetmessageid: <1550404261.96.0.889291213469.issue33935@roundup.psfhosted.org>
2019-02-17 11:51:01giampaolo.rodolalinkissue33935 messages
2019-02-17 11:51:01giampaolo.rodolacreate