mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Warn if state_changed events are excluded from recorder (#58021)
This commit is contained in:
parent
f25d3cf9b3
commit
ab2ff45726
@ -249,6 +249,11 @@ async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool:
|
|||||||
)
|
)
|
||||||
exclude = conf[CONF_EXCLUDE]
|
exclude = conf[CONF_EXCLUDE]
|
||||||
exclude_t = exclude.get(CONF_EVENT_TYPES, [])
|
exclude_t = exclude.get(CONF_EVENT_TYPES, [])
|
||||||
|
if EVENT_STATE_CHANGED in exclude_t:
|
||||||
|
_LOGGER.warning(
|
||||||
|
"State change events are excluded, recorder will not record state changes."
|
||||||
|
"This will become an error in Home Assistant Core 2022.2"
|
||||||
|
)
|
||||||
instance = hass.data[DATA_INSTANCE] = Recorder(
|
instance = hass.data[DATA_INSTANCE] = Recorder(
|
||||||
hass=hass,
|
hass=hass,
|
||||||
auto_purge=auto_purge,
|
auto_purge=auto_purge,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user