Pigotka / ha-cc-jablotron-cloud

HACS custom component for jablotron cloud integration
GNU General Public License v3.0
11 stars 1 forks source link

Unexpected error for call_service at pos 2 #18

Closed iwanvandaele closed 3 months ago

iwanvandaele commented 3 months ago

HA version:

Core: 2024.5.0 Supervisor:2024.04.4 Operating System:12.2 Frontend:20240501.0

Error:

Error executing script. Unexpected error for call_service at pos 2: Detected that custom integration 'jablotron_cloud' calls async_write_ha_state from a thread at custom_components/jablotron_cloud/alarm_control_panel.py, line 160: self.async_write_ha_state(). Please report it to the author of the 'jablotron_cloud' custom integration. Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 501, in _async_step await getattr(self, handler)() File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 736, in _async_call_service_step response_data = await self._async_run_long_action( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 699, in _async_run_long_action return await long_task ^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2738, in async_call response_data = await coro ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2779, in _execute_service return await target(service_call) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 975, in entity_service_call single_response = await _handle_entity_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1047, in _handle_entity_call result = await task ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/alarm_control_panel/init.py", line 175, in async_alarm_disarm await self.hass.async_add_executor_job(self.alarm_disarm, code) File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, **self.kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/jablotron_cloud/alarm_control_panel.py", line 160, in alarm_disarm self.async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1008, in async_write_ha_state self.hass.verify_event_loop_thread("async_write_ha_state") File "/usr/src/homeassistant/homeassistant/core.py", line 440, in verify_event_loop_thread frame.report( File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 162, in report _report_integration(what, integration_frame, level, error_if_integration) File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 203, in _report_integration raise RuntimeError( RuntimeError: Detected that custom integration 'jablotron_cloud' calls async_write_ha_state from a thread at custom_components/jablotron_cloud/alarm_control_panel.py, line 160: self.async_write_ha_state(). Please report it to the author of the 'jablotron_cloud' custom integration.

Pigotka commented 3 months ago

Cause by new Core: 2024.5.0. This core is not yet supported by this intergration.

Pigotka commented 3 months ago

Fixed. Will be in new release.