[issue15556] os.stat fails for file pending delete on Windows

Tim Golden report at bugs.python.org
Thu Oct 24 22:09:41 CEST 2013


Tim Golden added the comment:

Had a to-and-fro on IRC with RDM who highlighted that an inconsistency between os.listdir and os.path.exists (the case here) is, at least, undesirable. As it stands, our os.exists on os.stat mechanism will fail because any attempt to get any kind of handle via CreateFile will fail once the file is unlinked. However, FindFirstFile succeeds (hence os.listdir).

I'll put forward a patch to see whether it's worth pursuing.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue15556>
_______________________________________


More information about the Python-bugs-list mailing list