You cannot really do that*. Use a flag or something that the thread checks if it should shut down.
/Simon * well actually you can, sort of by using int PyThreadState_SetAsyncExc( long id, PyObject *exc) from C API. However, if you do that you swap one problem for a sh*tload of others, because of the *async* part. -- http://mail.python.org/mailman/listinfo/python-list