Remove entity description mixin in Venstar (#112964)

pull/111502/head
Joost Lekkerkerker 2024-03-11 11:53:40 +01:00 committed by GitHub
parent 90769b460d
commit 39bfb2b5ba
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 8 deletions

View File

@ -66,20 +66,15 @@ SCHEDULE_PARTS: dict[int, str] = {
}
@dataclass(frozen=True)
class VenstarSensorTypeMixin:
"""Mixin for sensor required keys."""
@dataclass(frozen=True, kw_only=True)
class VenstarSensorEntityDescription(SensorEntityDescription):
"""Base description of a Sensor entity."""
value_fn: Callable[[VenstarDataUpdateCoordinator, str], Any]
name_fn: Callable[[str], str]
uom_fn: Callable[[Any], str | None]
@dataclass(frozen=True)
class VenstarSensorEntityDescription(SensorEntityDescription, VenstarSensorTypeMixin):
"""Base description of a Sensor entity."""
async def async_setup_entry(
hass: HomeAssistant,
config_entry: ConfigEntry,