That error means a “mode” state received from MQTT is not in the list you configured.
The error displays the mode it received, which seems blank/empty/null here.
That doesn’t seem to work and it just goes back to unknown.
These are the full details of what I suspect are the issue (I added four Drayton Wiser TRVs the other day) as shown in HA and Zigbee2MQTT
I am also seeing exactly the same number of warnings for
Template variable warning: 'dict object' has no attribute 'system_mode' when rendering '{{ value_json.system_mode }}'
08:32:48 – (WARNING) helpers/template.py - message first occurred at 9 November 2021, 17:01:07 and shows up 11816 times
Which I guess means there is no system_mode value being sent. Is this an issue with the TRV, Zigbee2MQTT or configuration?
There are obviously thousands of these errors (now ~12k) which is starting to fill up logs and ignoring them will lead to space running out at some point. Is there anyway I can workout what is going on ?
Select the device, go to Dev Console, select Endpoint (should be 1), Cluster: havcThermostat, Attribute: systemMode.
Push Read button.
The answer should be the info like in my picture.
Now in HA, my TRV has the attribute systemMode.