diff --git a/homeassistant/components/ovo_energy/__init__.py b/homeassistant/components/ovo_energy/__init__.py index aa05c83ae76..f8c23b4f4f0 100644 --- a/homeassistant/components/ovo_energy/__init__.py +++ b/homeassistant/components/ovo_energy/__init__.py @@ -99,12 +99,10 @@ class OVOEnergyEntity(CoordinatorEntity): self, coordinator: DataUpdateCoordinator, client: OVOEnergy, - key: str, ) -> None: """Initialize the OVO Energy entity.""" super().__init__(coordinator) self._client = client - self._attr_unique_id = key class OVOEnergyDeviceEntity(OVOEnergyEntity): diff --git a/homeassistant/components/ovo_energy/sensor.py b/homeassistant/components/ovo_energy/sensor.py index cd84fa5a5d6..16fd15bfbde 100644 --- a/homeassistant/components/ovo_energy/sensor.py +++ b/homeassistant/components/ovo_energy/sensor.py @@ -57,7 +57,6 @@ SENSOR_TYPES_ELECTRICITY: tuple[OVOEnergySensorEntityDescription, ...] = ( name="OVO Last Electricity Cost", device_class=DEVICE_CLASS_MONETARY, state_class=STATE_CLASS_TOTAL_INCREASING, - icon="mdi:cash-multiple", value=lambda usage: usage.electricity[-1].consumption, ), OVOEnergySensorEntityDescription( @@ -157,8 +156,8 @@ class OVOEnergySensor(OVOEnergyDeviceEntity, SensorEntity): super().__init__( coordinator, client, - f"{DOMAIN}_{client.account_id}_{description.key}", ) + self._attr_unique_id = f"{DOMAIN}_{client.account_id}_{description.key}" self.entity_description = description @property