mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Attach template triggers at start eagerly (#113120)
This method calls async_initialize_triggers which is likely to never suspend and the attach can avoid being scheduled on the event loop
This commit is contained in:
parent
42527862e0
commit
51f871227e
@ -47,7 +47,7 @@ class TriggerUpdateCoordinator(DataUpdateCoordinator):
|
|||||||
await self._attach_triggers()
|
await self._attach_triggers()
|
||||||
else:
|
else:
|
||||||
self._unsub_start = self.hass.bus.async_listen_once(
|
self._unsub_start = self.hass.bus.async_listen_once(
|
||||||
EVENT_HOMEASSISTANT_START, self._attach_triggers
|
EVENT_HOMEASSISTANT_START, self._attach_triggers, run_immediately=True
|
||||||
)
|
)
|
||||||
|
|
||||||
for platform_domain in PLATFORMS:
|
for platform_domain in PLATFORMS:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user