how to drop all thread ??
Chris S.
chrisks at NOSPAM.udel.edu
Tue Nov 30 01:27:18 EST 2004
More information about the Python-list mailing list
Tue Nov 30 01:27:18 EST 2004
- Previous message (by thread): how to drop all thread ??
- Next message (by thread): Python-list Digest, Vol 14, Issue 377
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Leon wrote: > if class A( > use threading,thread module > ) to produce 100 thread,how to drop its (100 thread) when its running As Roggisch suggests, the cleanest way is if the thread kills itself once signaled by an exit condition. However, there is a non-orthodox way of pseudo-forcibly killing threads by catching the kill signal in a traceback. This method is summed up in Connelly Barnes's informal KThread module: http://www.google.com/groups?q=KThread+group:comp.lang.python&hl=en&lr=&selm=mailman.225.1083634398.25742.python-list%40python.org&rnum=1 Note it won't work in all cases, as it can't kill a thread that's made a blocking system call. However, it may come in useful.
- Previous message (by thread): how to drop all thread ??
- Next message (by thread): Python-list Digest, Vol 14, Issue 377
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list