On 8/11/06, Josiah Carlson <[EMAIL PROTECTED]> wrote: > Slawomir Nowaczyk <[EMAIL PROTECTED]> wrote: > > But it should not be done lightly and never when the code is not > > specifically expecting it. > > If you don't want random exceptions being raised in your threads, then > don't use this method that is capable of raising exceptions somewhat > randomly.
I agree. The only question is how dire the warnings should be. I'll answer that question with another question: Are we going to make the standard library robust against asynchronous exceptions? For example, class Thread has an attribute __stopped that is set using code similar to the example code I posted. An exception at just the wrong time would kill the thread while leaving __stopped == False. Maybe that particular case is worth fixing, but to find and fix them all? Better to put strong warnings on this one method: may cause unpredictable brokenness. -j _______________________________________________ Python-3000 mailing list [email protected] http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com
