Hello,
i have Smartmi Humidifier Evaporator 2 (CJXJSQ04ZM, zhimi.humidifier.ca4) which integrated into HA with syssi/xiaomi_airpurifier custom component.
Works great but… periodically becomes unavailable. This is not a problem if I didn’t want to use automation: send a message via the notification service if the water level in the humidifier is below a certain value. For this, the following automation was created:
It works fine, but if the water level is less than the set value and the humidifier changes its state to “unavailable”, then I receive repeated messages via the notification service and an error in the log:
Logger: homeassistant.helpers.condition
Source: helpers/condition.py:234
First occurred: 16 декабря 2020 г., 22:49:06 (102 occurrences)
Last logged: 11:26:11
Value cannot be processed as a number: <state sensor.airhumidifier_level=; unit_of_measurement=%, friendly_name=Air Humidifier Level, icon=mdi:water-percent @ 2020-12-18T10:47:11.687635+03:00> (Offending entity: )
How to avoid duplicate messages when the status of the humidifier changes?
Is unavailable the correct state when it’s unavailable? (Check in history)
Also what does it show in template editor? Should also say true if it’s not unavailable.
but history for the device shows that it changes it’s state to “unviable” (if i understand right it doesn’t matter that in frontend i see it on my local language as “недоступно” )