From bcf9b3e06b59b19fa2a08becde138aecaa3244f8 Mon Sep 17 00:00:00 2001 From: avollkopf <43980694+avollkopf@users.noreply.github.com> Date: Sat, 25 Mar 2023 18:50:36 +0100 Subject: [PATCH] improved handling in cancelling the mqtt subscription --- cbpi/__init__.py | 2 +- cbpi/controller/satellite_controller.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cbpi/__init__.py b/cbpi/__init__.py index cf50002..9b0b24d 100644 --- a/cbpi/__init__.py +++ b/cbpi/__init__.py @@ -1,3 +1,3 @@ -__version__ = "4.1.7.a11" +__version__ = "4.1.7.a12" __codename__ = "Groundhog Day" diff --git a/cbpi/controller/satellite_controller.py b/cbpi/controller/satellite_controller.py index d11885e..47779dd 100644 --- a/cbpi/controller/satellite_controller.py +++ b/cbpi/controller/satellite_controller.py @@ -164,10 +164,10 @@ class SatelliteController: except asyncio.CancelledError: # Cancel self.logger.warning("Sub Cancelled") + break except MqttError as e: self.logger.error("Sub MQTT Exception: {}".format(e)) except Exception as e: self.logger.error("Sub Exception: {}".format(e)) - # wait before try to resubscribe await asyncio.sleep(5)