Timer module?
Lenny Self
lenny at squiggie.com
Tue Jan 30 15:41:45 EST 2001
Lee, Rick wrote:
> The sleep() function in the time module blocks.
>
>
>
> I wonder if there is already any timer module out there that allows me
>
> to:
>
>
>
> - set a timer without blocking the current thread
>
> - cancel the timer
>
> - maybe also, able to tell it to recur at a given interval for so many
>
> times; and able to change that
>
> - create thousands of timers with a performance penalty that grows
>
> slower than linearly with the number of timers; preferably a performance
>
> cost that is small and almost constant
>
>
>
> Thanks.
>
>
>
> - Rick Lee
Take a look at the time module. It should help you out.
import time
time.sleep(<number of seconds>)
-- Lenny
More information about the Python-list
mailing list