Hi,
Is there a recommendation for when a comm needs to call an async function. While support for #433 would be ideal, the usecase is that there is some async def foo() that needs to be called from within a comm. For now, the best way to work around this was to make it synchronous via (using ideas from ipython/ipython#13670 (comment)):
import nest_asyncio
nest_asyncio.apply()
asyncio.run(foo())
This seems to work, but I didn't know if there was a better way.
Hi,
Is there a recommendation for when a comm needs to call an async function. While support for #433 would be ideal, the usecase is that there is some
async def foo()that needs to be called from within a comm. For now, the best way to work around this was to make it synchronous via (using ideas from ipython/ipython#13670 (comment)):This seems to work, but I didn't know if there was a better way.