# RuntimeWarning: coroutine 'foo' was never awaited

- **ID:** `python/asyncio-coroutine-was-never-awaited`
- **Domain:** python
- **Category:** runtime_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

A coroutine function was called but the returned coroutine object was never awaited or scheduled, usually by forgetting await or passing it to a non-async API.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 3.8 | active | — | — |
| 3.9 | active | — | — |
| 3.10 | active | — | — |
| 3.11 | active | — | — |
| 3.12 | active | — | — |

## Workarounds

1. **** (98% success)
   ```
   Add the missing await:

async def main():
    result = await foo()  # was: foo()
   ```
2. **** (90% success)
   ```
   If you only want to schedule it, wrap with asyncio.create_task():

asyncio.create_task(foo())
   ```

## Dead Ends

- **** — Hides the symptom while the coroutine body never executes, causing silent data loss and downstream bugs. (95% fail)
- **** — Raises RuntimeError: asyncio.run() cannot be called from a running event loop. (85% fail)
