[pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci
This commit is contained in:
pre-commit-ci[bot] 2026-09-10 09:07:00 +00:00
commit 2a95703378
3 changed files with 9 additions and 7 deletions

View file

@ -10,15 +10,15 @@ from homeassistant.core import callback
from homeassistant.helpers.selector import EntitySelector, EntitySelectorConfig
from .const import ( # pylint: disable=unused-import
SECTION_SLEEP,
SECTION_SUNRISE,
SECTION_SUNSET,
SECTION_TRANSITION,
SECTION_MISC,
CONF_LIGHTS,
DOMAIN,
EXTRA_VALIDATION,
NONE_STR,
SECTION_MISC,
SECTION_SLEEP,
SECTION_SUNRISE,
SECTION_SUNSET,
SECTION_TRANSITION,
VALIDATION_TUPLES,
)
from .switch import validate
@ -196,7 +196,7 @@ class OptionsFlowHandler(config_entries.OptionsFlow):
}
full_schema: dict[vol.Marker, Any] = {}
section_schemas: dict[str, dict[vol.Marker, Any]] = {
name: {} for name in self.SECTION_MAP
}

View file

@ -396,10 +396,12 @@ SECTION_MISC: set[str] = {
CONF_EXPAND_LIGHT_GROUPS,
}
def int_between(min_int: int, max_int: int) -> vol.All:
"""Return an integer between 'min_int' and 'max_int'."""
return vol.All(vol.Coerce(int), vol.Range(min=min_int, max=max_int))
VALIDATION_TUPLES: list[tuple[str, Any, Any]] = [
# Basic
(CONF_LIGHTS, DEFAULT_LIGHTS, cv.entity_ids), # type: ignore[arg-type]

View file

@ -267,4 +267,4 @@
"description": "Markiere, ob ein Licht \"manuell gesteuert\" ist."
}
}
}
}