*Quick edit for spelling errors.
Okay I did a fresh install of Home Assistant, just to leave out any possible bias.
I seem to have narrowed down the issue, the automation seems to trigger the script correctly, but the Danfoss does not open/close accordingly. When i look at the logs there are quite a few errors for both script and automation:
Logger: homeassistant.components.automation.tem01_update_external_temp_bathroom
Source: components/zha/core/device.py:518
Integration: Automation ([documentation](https://www.home-assistant.io/integrations/automation), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+automation%22))
First occurred: 12:17:03 (106 occurrences)
Last logged: 12:42:50
* TEM01 - Update External Temp - Bathroom: Error executing script. Unexpected error for call_service at pos 1: 513
* While executing automation automation.tem01_update_external_temp_bathroom
Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 262, in _async_step await getattr( File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 466, in _async_call_service_step await self._async_run_long_action(service_task) File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 428, in _async_run_long_action long_task.result() File "/usr/src/homeassistant/homeassistant/core.py", line 1488, in async_call task.result() File "/usr/src/homeassistant/homeassistant/core.py", line 1523, in _execute_service await handler.job.target(service_call) File "/usr/src/homeassistant/homeassistant/components/script/__init__.py", line 218, in service_handler await script_entity.async_turn_on( File "/usr/src/homeassistant/homeassistant/components/script/__init__.py", line 323, in async_turn_on await coro File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1041, in async_run await asyncio.shield(run.async_run()) File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 254, in async_run await self._async_step(log_exceptions=False) File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 262, in _async_step await getattr( File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 463, in _async_call_service_step await service_task File "/usr/src/homeassistant/homeassistant/core.py", line 1488, in async_call task.result() File "/usr/src/homeassistant/homeassistant/core.py", line 1523, in _execute_service await handler.job.target(service_call) File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 712, in admin_handler await result File "/usr/src/homeassistant/homeassistant/components/zha/api.py", line 922, in set_zigbee_cluster_attributes response = await zha_device.write_zigbee_attribute( File "/usr/src/homeassistant/homeassistant/components/zha/core/device.py", line 553, in write_zigbee_attribute cluster = self.async_get_cluster(endpoint_id, cluster_id, cluster_type) File "/usr/src/homeassistant/homeassistant/components/zha/core/device.py", line 518, in async_get_cluster return clusters[endpoint_id][cluster_type][cluster_id] KeyError: 513
and
Logger: homeassistant.components.script.bathroom_temp_follow
Source: components/zha/core/device.py:518
Integration: Scripts ([documentation](https://www.home-assistant.io/integrations/script), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+script%22))
First occurred: 12:10:40 (54 occurrences)
Last logged: 12:42:50
Bathroom Temp Follow: Error executing script. Unexpected error for call_service at pos 1: 513
`Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 262, in _async_step await getattr( File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 463, in _async_call_service_step await service_task File "/usr/src/homeassistant/homeassistant/core.py", line 1488, in async_call task.result() File "/usr/src/homeassistant/homeassistant/core.py", line 1523, in _execute_service await handler.job.target(service_call) File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 712, in admin_handler await result File "/usr/src/homeassistant/homeassistant/components/zha/api.py", line 922, in set_zigbee_cluster_attributes response = await zha_device.write_zigbee_attribute( File "/usr/src/homeassistant/homeassistant/components/zha/core/device.py", line 553, in write_zigbee_attribute cluster = self.async_get_cluster(endpoint_id, cluster_id, cluster_type) File "/usr/src/homeassistant/homeassistant/components/zha/core/device.py", line 518, in async_get_cluster return clusters[endpoint_id][cluster_type][cluster_id] KeyError: 513
Any idea what this could be? Perhaps related to the script’s endpoint, cluster type and id? Or perhaps the Danfoss firmware?