Killing a thread

Fredrik Lundh fredrik at pythonware.com
Sat Jun 10 15:11:52 EDT 2006


crazymykl at gmail.com wrote:

>> it cannot be done in a portable way, so that's not very likely.

>   def __run(self):
>     """Hacked run function, which installs the trace."""
>     sys.settrace(self.globaltrace)
>     self.__run_backup()
>     self.run = self.__run_backup

I'm not sure using a non-portable API to run the code under a "custom 
debugger" qualifies as a "portable implementation", though...

have you benchmarked this, btw?

</F>




More information about the Python-list mailing list