Don't show traceback when interrupting with ctrl-c

master
Ferry Boender 4 years ago
parent 40f9f95a4f
commit 79c3232d08
  1. 3
      src/scriptform.py

@ -117,7 +117,10 @@ class ScriptForm(object):
self.httpd.daemon_threads = True self.httpd.daemon_threads = True
self.log.info("Listening on %s:%s", listen_addr, listen_port) self.log.info("Listening on %s:%s", listen_addr, listen_port)
self.running = True self.running = True
try:
self.httpd.serve_forever() self.httpd.serve_forever()
except KeyboardInterrupt:
pass
self.running = False self.running = False
def shutdown(self): def shutdown(self):

Loading…
Cancel
Save