Martin v. Löwis added the comment:

Looking at the ReactOS sources, it appears that Windows doesn't do any 
rounding, so it's all Python's fault. Windows keeps its system time (in 
KI_USER_SHARED_DATA) in essentially a FILETIME represenation (i.e. units of 
100ns since 1601), and never needs to convert it. So CreateFile just uses the 
current system time as-is when filling the LastWriteTime.

I don't think it's enough for Python to convert these monotonically. The error 
would already occur if Python cannot convert bijectively, i.e. if getting the 
system time into float and back won't get the same FILETIME. It might just be 
that a 64-bit float value (with 53 bit mantissa) is too imprecise for that 
operation. A FILETIME currently has 56 significant bits.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue19715>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to