bug report: [ #447945 ] time.time() is not non-decreasing

zooko at zooko.com zooko at zooko.com
Sat Aug 4 12:04:04 EDT 2001


 Skip Montanaro wrote:
>
> How long should I wait for this to print out an error message?  On my
> Mandrake 8.0 system running Python 2.1.1 I'm letting it run (and run, and
> run) and have not so far seen a problem.

Hm.  I took your modified version of my test script and added to the end:

print "i, ", i

And I get plenty of errors...

Hm.  strace tells me that this is what is happening:

------- begin included strace output
gettimeofday({996940586, 982012}, NULL) = 0
gettimeofday({996940586, 982154}, NULL) = 0
gettimeofday({996940586, 982295}, NULL) = 0
gettimeofday({996940586, 982435}, NULL) = 0
gettimeofday({996940586, 982576}, NULL) = 0
gettimeofday({996940586, 982718}, NULL) = 0
gettimeofday({996940586, 982859}, NULL) = 0
gettimeofday({996940586, 976989}, NULL) = 0
fstat(1, {st_mode=S_IFIFO|0600, st_size=0, ...}) = 0
old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x4001a000
rt_sigaction(SIGINT, NULL, {0x400bbb50, [], 0x4000000}, 8) = 0
rt_sigaction(SIGINT, {SIG_DFL}, NULL, 8) = 0
write(1, "this is WRONG: ox: 996940586.983"..., 59this is WRONG: ox: 996940586.983, x: 996940586.977

i,  55
) = 59

------- begin included strace output

So my `gettimeofday()' sometimes returns a decreasing value.

Hm.  So I suppose I should report this as bug to debian...

What should I do with the bug report that I filed on sf.net?

Thanks for your help, Skip and Roman! 

Regards,

Zooko





More information about the Python-list mailing list