1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 21:06:19 +00:00

Add entity category 'system' (#58595)

* Add entity category 'hidden'

* Update cloud

* Update Google assistant

* Update Alexa

* Fix tests

* Add ENTITY_CATEGORIES constant

* Rename ENTITY_CATEGORY_HIDDEN to ENTITY_CATEGORY_SYSTEM

* Correct import in motioneye
This commit is contained in:
Erik Montnemery
2021-10-28 14:36:41 +02:00
committed by GitHub
parent 8c5832ae82
commit a0a8b9db26
12 changed files with 66 additions and 64 deletions

View File

@@ -20,8 +20,7 @@ from homeassistant.const import (
CONF_SERVICE_DATA,
CONF_SERVICE_TEMPLATE,
CONF_TARGET,
ENTITY_CATEGORY_CONFIG,
ENTITY_CATEGORY_DIAGNOSTIC,
ENTITY_CATEGORIES,
ENTITY_MATCH_ALL,
ENTITY_MATCH_NONE,
)
@@ -367,10 +366,7 @@ def async_extract_referenced_entity_ids(
for ent_entry in ent_reg.entities.values():
# Do not add config or diagnostic entities referenced by areas or devices
if ent_entry.entity_category in (
ENTITY_CATEGORY_CONFIG,
ENTITY_CATEGORY_DIAGNOSTIC,
):
if ent_entry.entity_category in ENTITY_CATEGORIES:
continue
if (