Faqts : Business : Programming : Shopping For You : Python : Common Problems : Threads

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

19 of 32 people (59%) answered Yes
Recently 5 of 10 people (50%) answered Yes

Entry

Is there a way to "kill" a thread that is currently asleep?
Can I stop, destroy, suspend, etc. a thread that is asleep?

Jun 19th, 2003 06:53
Denis Walrave, unknown unknown, Jeff Blaine


You can use the Event class:

http://www.python.org/doc/current/lib/event-objects.html

Denis.

----

From: http://www.python.org/doc/current/lib/module-threading.html

"Python's Thread class supports a subset of the behavior of Java's 
Thread class; currently, there are no priorities, no thread groups, 
and 
threads cannot be destroyed, stopped, suspended, resumed, or 
interrupted...."