diff --git a/custom_components/xiaomi_home/miot/miot_device.py b/custom_components/xiaomi_home/miot/miot_device.py index 6144d57..103a7c3 100644 --- a/custom_components/xiaomi_home/miot/miot_device.py +++ b/custom_components/xiaomi_home/miot/miot_device.py @@ -628,7 +628,7 @@ def unit_convert(self, spec_unit: str) -> Optional[str]: # pylint: disable=import-outside-toplevel from homeassistant.const import UnitOfConductivity unit_map['μS/cm'] = UnitOfConductivity.MICROSIEMENS_PER_CM - except ImportError: + except Exception: # pylint: disable=broad-except unit_map['μS/cm'] = 'μS/cm' return unit_map.get(spec_unit, None)