Skip to content

Commit d7a1ff9

Browse files
AJediIAmgithub-actions[bot]
authored andcommitted
chore: format code with ruff
1 parent 59e17ea commit d7a1ff9

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

custom_components/luxtronik/climate.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@
149149
visibility=LuxVisibility.V0023_FLOW_IN_TEMPERATURE,
150150
device_key=DeviceKey.heating,
151151
max_firmware_version=Version("3.90.0"),
152-
),
152+
),
153153
LuxtronikClimateDescription(
154154
key=SensorKey.COOLING,
155155
hvac_modes=[HVACMode.COOL, HVACMode.OFF],
@@ -297,7 +297,7 @@ def _handle_coordinator_update(
297297
self._attr_current_temperature = state_as_number_or_none(temp, 0.0)
298298
elif key != LuxCalculation.UNSET:
299299
self._attr_current_temperature = get_sensor_data(data, key)
300-
300+
301301
key_tar = self.entity_description.luxtronik_key_target_temperature
302302
if key_tar == LuxParameter.P1148_HEATING_TARGET_TEMP_ROOM_THERMOSTAT:
303303
self._attr_target_temperature = get_sensor_data(data, key_tar) / 10
@@ -306,7 +306,9 @@ def _handle_coordinator_update(
306306

307307
if key_tar == LuxCalculation.C0228_ROOM_THERMOSTAT_TEMPERATURE_TARGET:
308308
correction_factor = get_sensor_data(
309-
data, self.entity_description.luxtronik_key_correction_factor.value, False
309+
data,
310+
self.entity_description.luxtronik_key_correction_factor.value,
311+
False,
310312
)
311313
# LOGGER.info(f"self._attr_target_temperature={self._attr_target_temperature}")
312314
# LOGGER.info(f"self._attr_current_temperature={self._attr_current_temperature}")
@@ -319,7 +321,9 @@ def _handle_coordinator_update(
319321
and self._attr_current_temperature > 0.0
320322
and correction_factor is not None # noqa: W503
321323
):
322-
delta_temp = self._attr_target_temperature - self._attr_current_temperature
324+
delta_temp = (
325+
self._attr_target_temperature - self._attr_current_temperature
326+
)
323327
correction = round(
324328
delta_temp * (correction_factor / 100.0), 1
325329
) # correction_factor is in %, so need to divide by 100

0 commit comments

Comments
 (0)