Message206874
For more info on time, you can refer to the PEP 418.
I may be interesting to add "sleep" to time.get_clock_info(). time.sleep()
uses WaitForSingleObject() on windows. It may use internally a different
clock with a different resolution than time.monoyonic (GetTickCount). The
PEP says "WaitForSingleObject(): use the same timer than GetTickCount()
with the same precision."
I don't think that it's very useful to investigate the rounding issue on
Windows. The resolution of Windows clocks is very coarse (15 ms, 10^-2)
compared to Unix clocks (usually a few nanoseconds, 10^-9)... I changed
recently the unit test to check if a sleep of 0.5 seconds gives a time
delta of at least 0.5 seconds. The minimum delta can be set to 0.45 sec
with a comment refering to this issue. |
|
Date |
User |
Action |
Args |
2013-12-23 21:32:43 | vstinner | set | recipients:
+ vstinner, tim.peters, christian.heimes, python-dev, zach.ware |
2013-12-23 21:32:43 | vstinner | link | issue19999 messages |
2013-12-23 21:32:42 | vstinner | create | |
|