Check loop context
smurfix opened this issue · comments
Now that we have contextvar support, add one that remembers whether we're currently in an asyncio or a Trio context.
This shall catch erroneous nested calls of run_asyncio
and run_trio
. Missing calls to these might be possible but needs to be invesigated further.
Update: use sniffio to do that