Plugwise fixes from quality review (#132158)

This commit is contained in:
Tom 2024-12-03 12:34:03 +01:00 committed by GitHub
parent 003d4d712a
commit aeab8a0143
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 2 additions and 14 deletions

View File

@ -34,7 +34,6 @@ class PlugwiseBinarySensorEntityDescription(BinarySensorEntityDescription):
BINARY_SENSORS: tuple[PlugwiseBinarySensorEntityDescription, ...] = (
PlugwiseBinarySensorEntityDescription(
key="low_battery",
translation_key="low_battery",
device_class=BinarySensorDeviceClass.BATTERY,
entity_category=EntityCategory.DIAGNOSTIC,
),
@ -56,7 +55,6 @@ BINARY_SENSORS: tuple[PlugwiseBinarySensorEntityDescription, ...] = (
PlugwiseBinarySensorEntityDescription(
key="flame_state",
translation_key="flame_state",
name="Flame state",
entity_category=EntityCategory.DIAGNOSTIC,
),
PlugwiseBinarySensorEntityDescription(

View File

@ -60,7 +60,6 @@ async def async_setup_entry(
class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity):
"""Representation of a Plugwise thermostat."""
_attr_has_entity_name = True
_attr_name = None
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_translation_key = DOMAIN
@ -75,7 +74,6 @@ class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity):
) -> None:
"""Set up the Plugwise API."""
super().__init__(coordinator, device_id)
self._attr_extra_state_attributes = {}
self._attr_unique_id = f"{device_id}-climate"
self._devices = coordinator.data.devices

View File

@ -16,9 +16,7 @@ rules:
status: todo
comment: Clean up coordinator (L71) check for mypy happiness
entity-unique-id: done
has-entity-name:
status: todo
comment: Clean up climate (already in superclass)
has-entity-name: done
entity-event-setup: done
dependency-transparency: done
action-setup:
@ -62,9 +60,7 @@ rules:
status: exempt
comment: Plugwise has no options flow
## Gold
entity-translations:
status: todo
comment: Clean up name where not needed, remove translation key on deviceclasses
entity-translations: done
entity-device-class: done
devices: done
entity-category: done

View File

@ -30,9 +30,6 @@
},
"entity": {
"binary_sensor": {
"low_battery": {
"name": "Battery state"
},
"compressor_state": {
"name": "Compressor state"
},

View File

@ -48,7 +48,6 @@ SWITCHES: tuple[PlugwiseSwitchEntityDescription, ...] = (
PlugwiseSwitchEntityDescription(
key="cooling_ena_switch",
translation_key="cooling_ena_switch",
name="Cooling",
entity_category=EntityCategory.CONFIG,
),
)