217 files

This commit is contained in:
Home Assistant Version Control
2026-07-30 23:59:38 +00:00
parent d43a63ad29
commit 7b5e46e702
217 changed files with 15978 additions and 3912 deletions
@@ -50,7 +50,6 @@ class ProfileLibrary:
self._loader = loader
self._profiles: dict[str, list[PowerProfile]] = {}
self._manufacturer_models: dict[str, set[tuple[str, str]]] = {}
self._manufacturer_device_types: dict[str, list] = {}
async def initialize(self) -> None:
await self._loader.initialize()
@@ -301,7 +300,12 @@ class ProfileLibrary:
return next(iter(matches))
async def _load_model_data(self, manufacturer: str, model: str, custom_directory: str | None) -> tuple[dict, str]:
async def _load_model_data(
self,
manufacturer: str,
model: str,
custom_directory: str | None,
) -> tuple[dict[str, Any], str]:
"""Load the model data from the appropriate directory."""
loader = (
LocalLoader(self._hass, custom_directory, is_custom_directory=True) if custom_directory else self._loader
@@ -317,8 +321,8 @@ class ProfileLibrary:
manufacturer: str,
model: str,
directory: str,
json_data: dict,
sub_profiles: list[tuple[str, dict]] | None = None,
json_data: dict[str, Any],
sub_profiles: list[tuple[str, dict[str, Any]]] | None = None,
) -> PowerProfile:
"""Create and initialize the PowerProfile object."""
profile = PowerProfile(