From 788d9571b51a5240017beab55a6744be6b6780ff Mon Sep 17 00:00:00 2001 From: epenet <6771947+epenet@users.noreply.github.com> Date: Mon, 23 Sep 2024 19:35:48 +0200 Subject: [PATCH] Add entity components to hass-enforce-class-module pylint plugin (#126545) --- pylint/plugins/hass_enforce_class_module.py | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/pylint/plugins/hass_enforce_class_module.py b/pylint/plugins/hass_enforce_class_module.py index c0b363bbddf..2b8a836dfb4 100644 --- a/pylint/plugins/hass_enforce_class_module.py +++ b/pylint/plugins/hass_enforce_class_module.py @@ -65,8 +65,21 @@ _MODULES: dict[str, set[str]] = { "WeatherEntityDescription", }, } -_ENTITY_COMPONENTS: set[str] = {platform.value for platform in Platform} -_ENTITY_COMPONENTS.add("tag") +_ENTITY_COMPONENTS: set[str] = {platform.value for platform in Platform}.union( + { + "automation", + "counter", + "input_boolean", + "input_datetime", + "input_number", + "input_text", + "person", + "script", + "tag", + "template", + "timer", + } +) class HassEnforceClassModule(BaseChecker):