

Python threads: communication and stopping - alexis-d
http://eli.thegreenplace.net/2011/12/27/python-threads-communication-and-stopping/

======
g3orge
I learn new things about Python every day.

------
oconnore
The "politely ask it to stop" paradigm is not a solution. For it to work, your
thread cannot perform any blocking calls, nor can it call out to any long
running functions that are not specifically designed to check a stop flag
frequently.

~~~
eliben
Yep, I explicitly mentioned this bit in the article. Then again, when your
thread performs some long blocking call and you want to kill it, you're out of
luck anyway. The advice in the post is directly applicable to problems where
the blocking calls aren't particularly long.

