Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RuntimeError: Detected that custom integration 'hass_agent' calls async_create_task from a thread #31

Open
kbirger opened this issue May 6, 2024 · 0 comments

Comments

@kbirger
Copy link

kbirger commented May 6, 2024

I'm seeing repeated errors from home assistant that indicate that this integration is calling async_create_task from a thread. I think this is related to an update of home assistant. The result is that some functionality, such as notifying the windows app does not work.

2024-05-06 17:27:15.644 WARNING (SyncWorker_49) [homeassistant.helpers.frame] Detected that custom integration 'hass_agent' calls async_create_task from a thread at custom_components/hass_agent/__init__.py, line 147: hass.async_create_task(handle_apis_changed(hass, entry, apis)), please report it to the author of the 'hass_agent' custom integration
2024-05-06 17:27:15.647 ERROR (SyncWorker_49) [homeassistant.util.logging] Exception in updated when handling msg on 'hass.agent/devices/XXXXX': '{"serial_number":XXXX","device":{"identifiers":"hass.agent-XXXX","manufacturer":"LAB02 Research","model":"Microsoft Windows NT 10.0.22631.0","name":"XXXX","sw_version":"2022.14.0"},"apis":{"notifications":true,"media_player":true}}'
Traceback (most recent call last):
  File "/config/custom_components/hass_agent/__init__.py", line 147, in updated
    hass.async_create_task(handle_apis_changed(hass, entry, apis))
  File "/usr/src/homeassistant/homeassistant/core.py", line 816, in async_create_task
    self.verify_event_loop_thread("async_create_task")
  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 'hass_agent' calls async_create_task from a thread at custom_components/hass_agent/__init__.py, line 147: hass.async_create_task(handle_apis_changed(hass, entry, apis)). Please report it to the author of the 'hass_agent' custom integration.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant