(async_fn)
| 43 | |
| 44 | |
| 45 | def _trio_runner(async_fn): |
| 46 | import trio |
| 47 | |
| 48 | async def loc(coro): |
| 49 | """ |
| 50 | We need the dummy no-op async def to protect from |
| 51 | trio's internal. See https://github.com/python-trio/trio/issues/89 |
| 52 | """ |
| 53 | return await coro |
| 54 | |
| 55 | return trio.run(loc, async_fn) |
| 56 | |
| 57 | |
| 58 | def _pseudo_sync_runner(coro): |