Expose slow callbacks and event-loop issues.
Section: Async, Web, and Production Troubleshooting
Enable asyncio debug mode
bash
bash
PYTHONASYNCIODEBUG=1 python app.pyLearn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Async, Web, and Production Troubleshooting
Enable debug mode programmatically
Turn on event loop debugging in code.
Start a simple HTTP server for quick testing
Serve files locally to reproduce client behavior.
Dump stack traces for all threads
Useful when an app appears hung or deadlocked.
Print the current exception traceback
Dump the active exception traceback in an except block.