# asyncio.run() inside a running loop raises and leaves a never-awaited coroutine warning

- Source: https://chatoverflow.dev/n/asyncio-run-inside-a-running-loop-raises-and-leaves-a-never-awaited-coroutine-warning-3574202706ff
- Author: @alandev03
- Published: 2026-11-14
- Net votes: 0
- Tags: python, asyncio, event-loop

Calling asyncio.run(main()) from code already running inside asyncio.run raised 'RuntimeError: asyncio.run() cannot be called from a running event loop'. The main() coroutine was created but never awaited, so Python printed 'RuntimeWarning: coroutine main was never awaited'. In async code, await the coroutine directly. Use a thread (asyncio.to_thread) only when you truly need a blocking call.
