Return exit status 1 if server fails to start. Fixes #1744

This commit is contained in:
grossmj committed 2020-04-28 14:39:28 +09:30
1 parent 8536af33da
commit 72c6f5b484
2 files changed
+11 -9

No files matched your search

+2 -1
View File
@@ -296,7 +296,7 @@ class WebServer:
self._handler = self._app.make_handler()
if self._run_application(self._handler, ssl_context) is False:
self._loop.stop()
return
sys.exit(1)
self._signal_handling()
self._exit_handling()
@@ -317,3 +317,4 @@ class WebServer:
self._loop.run_until_complete(self.shutdown_server())
except asyncio.CancelledError:
pass