wait is a very overloaded word in asyncio. Events and Conditions are not consistent with the rest of asyncio. Why don't Future and Task have wait() methods? well because they are awaitable Some subjective reasoning: Every time I go to use one of these things, I attempt to await them like everything else in the Asyncio world and get a nice exception for it. await event vs await event.wait() I propose we make conditions and events awaitable and deprecate the .wait or at-least remove it from the documentation.
Removed Condition from this request, because it has an __await__ method for supporting the the deprecated pattern with async cond: I'll open a different bug, for Condition behavior for 3.9 when we can remove the deprecated pattern.
> Deprecating Event.wait would be incorrect because Event was designed to mimic the threading.Event class which has a (blocking) wait() method[1]. This is rather important. I'd like to continue maintaining this similarity. Adding 'await event' would be similar (in a way) to making instances of threading.Event callable. So deprecation of '.wait()' isn't something we will do. Having *both* 'await event.wait()' and 'await event' worries me. IMO the slight readability improvement isn't worth the added complexity.
messages: + title: Asyncio Event.wait() and Condition.wait() is a hold over from before awaitable, and should be awaitable -> Asyncio Event.wait() is a hold over from before awaitable, and should be awaitable