Compare commits

...

1 Commits

Author SHA1 Message Date
Erik
1bd9d8a7be Save restore_state store in worker thread 2025-11-25 19:40:30 +01:00

View File

@@ -119,7 +119,11 @@ class RestoreStateData:
"""Initialize the restore state data class."""
self.hass: HomeAssistant = hass
self.store = Store[list[dict[str, Any]]](
hass, STORAGE_VERSION, STORAGE_KEY, encoder=JSONEncoder
hass,
STORAGE_VERSION,
STORAGE_KEY,
encoder=JSONEncoder,
serialize_in_event_loop=False,
)
self.last_states: dict[str, StoredState] = {}
self.entities: dict[str, RestoreEntity] = {}