aioconsole
aioconsole copied to clipboard
Why is InteractiveEventLoop an event loop?
Pardon my ignorance, but why is InteractiveEventLoop an event loop at all, rather than a coroutine? E.g. 66a2316703eed26b6381d5a15eec8227a931f4de.
The reason I care is because I want to use a uvloop rather than an asyncio.SelectorEventLoop.
It's not a perfect proposal -- there is some error on shutdown.
Interesting... So it cannot be a loop, it probably shouldn't be a policy either, and a coroutine is not enough cause we need proper cleanup on shutdown. Maybe it should be an asynchronous context manager.
The tricky part is the apython script, since it has to patch asyncio in a way that allows the interactive console to run regardless of the loop and the policy.