From d044567d38dfa076b24e60800b23090790326854 Mon Sep 17 00:00:00 2001 From: Michael Hansen Date: Thu, 7 Dec 2023 16:13:58 -0600 Subject: [PATCH] Expect disconnect --- wyoming_satellite/__main__.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/wyoming_satellite/__main__.py b/wyoming_satellite/__main__.py index 151ab01..4e532aa 100644 --- a/wyoming_satellite/__main__.py +++ b/wyoming_satellite/__main__.py @@ -486,6 +486,8 @@ class SatelliteEventHandler(AsyncEventHandler): except Exception: _LOGGER.exception("Unexpected error in run_satellite") + except ConnectionResetError: + _LOGGER.info("Server disconnected") async def run_satellite_wake(self) -> None: """Task to read mic input and do local wake word detection.""" @@ -578,6 +580,8 @@ class SatelliteEventHandler(AsyncEventHandler): pending.add(wake_task) except Exception: _LOGGER.exception("Unexpected error in run_satellite") + except ConnectionResetError: + _LOGGER.info("Server disconnected") # -------------------------------------------------------------------------