Antoine Pitrou <pit...@free.fr> added the comment: Ok, so digging a bit, the feature dates back to issue1674032. Interestingly, the OP in that issue had already envisioned that race condition and had precisely proposed the feature to avoid it: “Note that in the above case, the event could be cleared between the return from x.wait and the execution of x.isSet (in another thread), and so this would operate as though x.wait had just timed out”.
So I'm changing my mind and saying it seems desireable to return True if the wait succeeded before the timeout's end, even though the flag may have been reset in the meantime. In 3.2, Condition.wait also returns a boolean, meaning the check in Event.wait can be atomic. ---------- nosy: +neologix _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue13502> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com