zha-toolkit
zha-toolkit copied to clipboard
Error during setup of component zha_toolkit with v1.1.14 upgrade
Upon upgrading to v1.1.14, I immediately received the following error:
Error during setup of component zha_toolkit
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/setup.py", line 404, in _async_setup_component
result = await task
^^^^^^^^^^
File "/config/custom_components/zha_toolkit/__init__.py", line 660, in async_setup
await hass.async_add_executor_job(register_services, hass)
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/zha_toolkit/__init__.py", line 853, in register_services
hass.services.async_register(
File "/usr/src/homeassistant/homeassistant/core.py", line 2515, in async_register
self._hass.verify_event_loop_thread("hass.services.async_register")
File "/usr/src/homeassistant/homeassistant/core.py", line 463, in verify_event_loop_thread
frame.report_non_thread_safe_operation(what)
File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 225, in report_non_thread_safe_operation
report(
File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 159, in report
_report_integration(what, integration_frame, level, error_if_integration)
File "/usr/src/homeassistant/homeassistant/helpers/frame.py", line 197, in _report_integration
raise RuntimeError(
RuntimeError: Detected that custom integration 'zha_toolkit' calls hass.services.async_register from a thread other than the event loop, which may cause Home Assistant to crash or data to corrupt. For more information, see https://developers.home-assistant.io/docs/asyncio_thread_safety/#hassservicesasync_register at custom_components/zha_toolkit/__init__.py, line 853: hass.services.async_register(. Please report it to the author of the 'zha_toolkit' custom integration.