diff --git a/homeassistant/components/vesync/binary_sensor.py b/homeassistant/components/vesync/binary_sensor.py index 72a1e50a00b6..22bf8d57d537 100644 --- a/homeassistant/components/vesync/binary_sensor.py +++ b/homeassistant/components/vesync/binary_sensor.py @@ -101,7 +101,7 @@ def _setup_entities( ) -class VeSyncBinarySensor(BinarySensorEntity, VeSyncBaseEntity): +class VeSyncBinarySensor(BinarySensorEntity, VeSyncBaseEntity[VeSyncBaseDevice]): """Vesync binary sensor class.""" entity_description: VeSyncBinarySensorEntityDescription diff --git a/homeassistant/components/vesync/select.py b/homeassistant/components/vesync/select.py index a61d1e3dfd49..a24dd2bc28cc 100644 --- a/homeassistant/components/vesync/select.py +++ b/homeassistant/components/vesync/select.py @@ -200,7 +200,7 @@ def _setup_entities( ) -class VeSyncSelectEntity(VeSyncBaseEntity, SelectEntity): +class VeSyncSelectEntity(VeSyncBaseEntity[VeSyncBaseDevice], SelectEntity): """A class to set numeric options on Vesync device.""" entity_description: VeSyncSelectEntityDescription diff --git a/homeassistant/components/vesync/sensor.py b/homeassistant/components/vesync/sensor.py index 78f36a97e737..04c6808e6873 100644 --- a/homeassistant/components/vesync/sensor.py +++ b/homeassistant/components/vesync/sensor.py @@ -377,7 +377,7 @@ def _setup_entities( async_add_entities(entities, update_before_add=True) -class VeSyncSensorEntity(VeSyncBaseEntity, SensorEntity): +class VeSyncSensorEntity(VeSyncBaseEntity[VeSyncBaseDevice], SensorEntity): """Representation of a sensor describing a VeSync device.""" entity_description: VeSyncSensorEntityDescription @@ -437,7 +437,9 @@ class VeSyncSensorEntity(VeSyncBaseEntity, SensorEntity): @override def native_unit_of_measurement(self) -> str | None: """Return the unit the value was reported in by the sensor.""" - if self.entity_description.use_device_temperature_unit: + if self.entity_description.use_device_temperature_unit and is_air_fryer( + self.device + ): if self.device.temp_unit == TemperatureUnits.CELSIUS: return UnitOfTemperature.CELSIUS if self.device.temp_unit == TemperatureUnits.FAHRENHEIT: diff --git a/homeassistant/components/vesync/update.py b/homeassistant/components/vesync/update.py index 49dee33e203c..6177277ce93c 100644 --- a/homeassistant/components/vesync/update.py +++ b/homeassistant/components/vesync/update.py @@ -56,7 +56,7 @@ def _setup_entities( ) -class VeSyncDeviceUpdate(VeSyncBaseEntity, UpdateEntity): +class VeSyncDeviceUpdate(VeSyncBaseEntity[VeSyncBaseDevice], UpdateEntity): """Representation of a VeSync device update entity.""" _attr_device_class = UpdateDeviceClass.FIRMWARE