diff --git a/platypush/plugins/zigbee/mqtt/__init__.py b/platypush/plugins/zigbee/mqtt/__init__.py index 48087c517b..a7a89b3e40 100644 --- a/platypush/plugins/zigbee/mqtt/__init__.py +++ b/platypush/plugins/zigbee/mqtt/__init__.py @@ -1,4 +1,5 @@ import json +import re import threading from queue import Queue @@ -1396,6 +1397,7 @@ class ZigbeeMqttPlugin(MqttPlugin): # lgtm [py/missing-call-to-init] ) def _get_switch_info(self, device: str): + device = self._ieee_address(device) switches_info = self._get_switches_info() info = switches_info.get(device) if info: @@ -1430,11 +1432,19 @@ class ZigbeeMqttPlugin(MqttPlugin): # lgtm [py/missing-call-to-init] ) @staticmethod - def _ieee_address(device: dict) -> str: + def _ieee_address(device: Union[dict, str]) -> str: # Entity value IDs are stored in the `
: