Skip to content
Snippets Groups Projects
Commit f467f1e0 authored by Sybren A. Stüvel's avatar Sybren A. Stüvel
Browse files

Prevent hang at shutdown

parent 7be0ae2e
No related branches found
No related tags found
No related merge requests found
...@@ -162,7 +162,7 @@ def main(): ...@@ -162,7 +162,7 @@ def main():
shutdown_future.cancel() shutdown_future.cancel()
mir_work_task.cancel() mir_work_task.cancel()
try: try:
loop.run_until_complete(mir_work_task) loop.run_until_complete(asyncio.wait_for(mir_work_task, 5))
except requests.exceptions.ConnectionError: except requests.exceptions.ConnectionError:
log.warning("Unable to connect to HTTP server, but that's fine as we're shutting down.") log.warning("Unable to connect to HTTP server, but that's fine as we're shutting down.")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment