sanic: KEEP_ALIVE_TIMEOUT causing the changes in server (mode debug) to be delayed?
Describe the bug When running Sanic with the following options:
app.run(auto_reload=True, debug=True)
If I make any changes to my code and refresh, the new code is not taken into consideration. I need to wait a few seconds, and I’ll see the following message in the console:
[DEBUG] KeepAlive Timeout. Closing connection.
Reading the documentation, settings KEEP_ALIVE to False in dev mode would solve my issue, but it doesn’t change anything. The error still is displayed after about 8 seconds.
What can I do to have my new code refreshed immediately when running Sanic?
Expected behavior New code executed on refresh, not the previous one.
Environment (please complete the following information):
- OS: Fedora 24
- Version: 21.6.2
- Python: 3.8.10
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 25 (25 by maintainers)
I can provide a reproducible example, but probably not until Monday, so don’t be surprised if I don’t post anything until then 😃