diff --git a/src/Ui/UiServer.py b/src/Ui/UiServer.py index d2c40f17..263bb630 100644 --- a/src/Ui/UiServer.py +++ b/src/Ui/UiServer.py @@ -51,12 +51,16 @@ class UiWSGIHandler(WSGIHandler): ws_handler = WebSocketHandler(*self.args, **self.kwargs) ws_handler.__dict__ = self.__dict__ # Match class variables ws_handler.run_application() + except ConnectionAbortedError as err: + logging.warning("UiWSGIHandler websocket connection aborted: %s" % err) except Exception as err: logging.error("UiWSGIHandler websocket error: %s" % Debug.formatException(err)) self.handleError(err) else: # Standard HTTP request try: super(UiWSGIHandler, self).run_application() + except ConnectionAbortedError as err: + logging.warning("UiWSGIHandler connection aborted: %s" % err) except Exception as err: logging.error("UiWSGIHandler error: %s" % Debug.formatException(err)) self.handleError(err)