[Web-SIG] A 'shutdown' function in WSGI

Antoine Pitrou solipsis at pitrou.net
Tue Feb 21 15:02:39 CET 2012


Tarek Ziadé <ziade.tarek at ...> writes:
> 
> here's a very simple demo: http://tarek.pastebin.mozilla.org/1489505
> 
> There are two typos but the effect remains the same since you are locked
> before you reach those lines:
> - atexit call worker.stop() instead 
> of worker.join()
> - in worker.stop(), it calls worker.join() instead of
> worker.join(self)

I find your example convincing. I think that's worth fixing in Python (e.g. by 
offering an atexit() method on Thread objects). Perhaps you can open a bug?

Regards

Antoine.




More information about the Web-SIG mailing list