Migrate integrations i-m to extend SensorEntity (#48213)
This commit is contained in:
parent
64bc9a8196
commit
fdf97eaca3
62 changed files with 152 additions and 157 deletions
|
@ -1,4 +1,5 @@
|
|||
"""Support for UK Met Office weather service."""
|
||||
from homeassistant.components.sensor import SensorEntity
|
||||
from homeassistant.const import (
|
||||
ATTR_ATTRIBUTION,
|
||||
DEVICE_CLASS_HUMIDITY,
|
||||
|
@ -10,7 +11,6 @@ from homeassistant.const import (
|
|||
UV_INDEX,
|
||||
)
|
||||
from homeassistant.core import callback
|
||||
from homeassistant.helpers.entity import Entity
|
||||
from homeassistant.helpers.typing import ConfigType, HomeAssistantType
|
||||
|
||||
from .const import (
|
||||
|
@ -92,7 +92,7 @@ async def async_setup_entry(
|
|||
)
|
||||
|
||||
|
||||
class MetOfficeCurrentSensor(Entity):
|
||||
class MetOfficeCurrentSensor(SensorEntity):
|
||||
"""Implementation of a Met Office current weather condition sensor."""
|
||||
|
||||
def __init__(self, entry_data, hass_data, sensor_type):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue