threading module timer object

Mongryong Mongryong at sympatico.ca
Mon Feb 3 18:31:13 EST 2003


On Mon, 2003-02-03 at 18:09, .d.hos wrote:
> class workerThread(threading.Thread):
[snip]
>     def run(self):
>         try:           
>             t = threading.Timer(5.0, self.flagIt)
>             t.start()
[snip]

Another one of Python's Gotchas!  I believe this is what you want:

t=threading.Timer(5, workerThread.flagIt, self)

BTW, what you're doing is kind of 'hacky' (weird).  What is is that
you're try to to do?






More information about the Python-list mailing list