Trio allows using trio.from_thread.run and trio.from_thread.run_sync to be called from unrelated threads as long as a token (from trio.low_level.current.token) is provided.
On asyncio this token could be the event loop object itself, or another object that wraps it.
This change would likely allow us to remove the __new__() hack from BlockingPortal.
Trio allows using trio.from_thread.run and trio.from_thread.run_sync to be called from unrelated threads as long as a token (from trio.low_level.current.token) is provided.
On asyncio this token could be the event loop object itself, or another object that wraps it.
This change would likely allow us to remove the
__new__()hack fromBlockingPortal.