diff --git a/zha/zigbee/cluster_handlers/__init__.py b/zha/zigbee/cluster_handlers/__init__.py index 321b9e19..a2c1e321 100644 --- a/zha/zigbee/cluster_handlers/__init__.py +++ b/zha/zigbee/cluster_handlers/__init__.py @@ -8,6 +8,7 @@ from enum import Enum import functools import logging +import traceback from typing import TYPE_CHECKING, Any, Final, ParamSpec, TypedDict import zigpy.exceptions diff --git a/zha/zigbee/cluster_handlers/general.py b/zha/zigbee/cluster_handlers/general.py index e103f119..46bbbccc 100644 --- a/zha/zigbee/cluster_handlers/general.py +++ b/zha/zigbee/cluster_handlers/general.py @@ -627,9 +627,15 @@ def cluster_command( async def check_in_response(self, tsn: int) -> None: """Respond to checkin command.""" - await self.checkin_response(True, self.CHECKIN_FAST_POLL_TIMEOUT, tsn=tsn) - if self._endpoint.device.manufacturer_code not in self._IGNORED_MANUFACTURER_ID: - await self.set_long_poll_interval(self.LONG_POLL) + try: + await self.checkin_response(True, self.CHECKIN_FAST_POLL_TIMEOUT, tsn=tsn) + if ( + self._endpoint.device.manufacturer_code + not in self._IGNORED_MANUFACTURER_ID + ): + await self.set_long_poll_interval(self.LONG_POLL) + except Exception: + self.error(traceback.format_exc()) await self.fast_poll_stop() def skip_manufacturer_id(self, manufacturer_code: int) -> None: