[Tutor] quick question about threads
nephish
nephish at xit.net
Wed Jan 18 02:54:07 CET 2006
Hey there, i have a program written in python that uses four threads
that run all at the same time. Now i want to add a new thread with the
same basic structure (threading.thread) that will run only when needed.
This one will not run in a loop, it will just run once and quit.
So, i may need this to be running several times at once because it will
have a 15 second delay written into it.
My question is, after the script is done, will it be safe ? i mean, over
the course of a few days, it may run this thing a few hundred times. if
it is simple like this
threading.thread
print 'here is something to say'
time.sleep(15)
print 'here is something else'
do i need to include a special command to kill the thread, or will it
just finish and everything will be ok then ?
thanks for any tips.
shawn
More information about the Tutor
mailing list