mirror of
https://github.com/home-assistant/core.git
synced 2025-08-02 12:15:08 +02:00
Add restored to the set of attributes excluded from being recorded in the db (#70169)
* Add restored to the set of attributes excluded from being recorded in the database - Noticed on restart that the table gets 100s of new rows because of these * Update homeassistant/components/recorder/const.py
This commit is contained in:
@@ -4,7 +4,7 @@ from functools import partial
|
|||||||
import json
|
import json
|
||||||
from typing import Final
|
from typing import Final
|
||||||
|
|
||||||
from homeassistant.const import ATTR_ATTRIBUTION, ATTR_SUPPORTED_FEATURES
|
from homeassistant.const import ATTR_ATTRIBUTION, ATTR_RESTORED, ATTR_SUPPORTED_FEATURES
|
||||||
from homeassistant.helpers.json import JSONEncoder
|
from homeassistant.helpers.json import JSONEncoder
|
||||||
|
|
||||||
DATA_INSTANCE = "recorder_instance"
|
DATA_INSTANCE = "recorder_instance"
|
||||||
@@ -27,4 +27,4 @@ DB_WORKER_PREFIX = "DbWorker"
|
|||||||
|
|
||||||
JSON_DUMP: Final = partial(json.dumps, cls=JSONEncoder, separators=(",", ":"))
|
JSON_DUMP: Final = partial(json.dumps, cls=JSONEncoder, separators=(",", ":"))
|
||||||
|
|
||||||
ALL_DOMAIN_EXCLUDE_ATTRS = {ATTR_ATTRIBUTION, ATTR_SUPPORTED_FEATURES}
|
ALL_DOMAIN_EXCLUDE_ATTRS = {ATTR_ATTRIBUTION, ATTR_RESTORED, ATTR_SUPPORTED_FEATURES}
|
||||||
|
Reference in New Issue
Block a user