From ed9e73898515d38c2ae3d7c3fc2f1c76e5bda7e3 Mon Sep 17 00:00:00 2001 From: Jan-Philipp Benecke Date: Tue, 19 Dec 2023 10:35:04 +0100 Subject: [PATCH] Remove ipma entity description required fields mixin (#106039) --- homeassistant/components/ipma/sensor.py | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/homeassistant/components/ipma/sensor.py b/homeassistant/components/ipma/sensor.py index d779a7ae02a6..99e994069a59 100644 --- a/homeassistant/components/ipma/sensor.py +++ b/homeassistant/components/ipma/sensor.py @@ -23,18 +23,13 @@ from .entity import IPMADevice _LOGGER = logging.getLogger(__name__) -@dataclass(frozen=True) -class IPMARequiredKeysMixin: - """Mixin for required keys.""" +@dataclass(frozen=True, kw_only=True) +class IPMASensorEntityDescription(SensorEntityDescription): + """Describes a IPMA sensor entity.""" value_fn: Callable[[Location, IPMA_API], Coroutine[Location, IPMA_API, int | None]] -@dataclass(frozen=True) -class IPMASensorEntityDescription(SensorEntityDescription, IPMARequiredKeysMixin): - """Describes IPMA sensor entity.""" - - async def async_retrieve_rcm(location: Location, api: IPMA_API) -> int | None: """Retrieve RCM.""" fire_risk: RCM = await location.fire_risk(api)