diff --git a/homeassistant/helpers/entity_component.py b/homeassistant/helpers/entity_component.py index fe2d78c02ed..dc9093b362b 100644 --- a/homeassistant/helpers/entity_component.py +++ b/homeassistant/helpers/entity_component.py @@ -120,7 +120,9 @@ class EntityComponent(Generic[_EntityT]): Note: this is only required if the integration never calls `setup` or `async_setup`. """ - self.hass.bus.async_listen_once(EVENT_HOMEASSISTANT_STOP, self._async_shutdown) + self.hass.bus.async_listen_once( + EVENT_HOMEASSISTANT_STOP, self._async_shutdown, run_immediately=True + ) def setup(self, config: ConfigType) -> None: """Set up a full entity component.