Skip to content

Commit 21d9057

Browse files
committed
Fixup WIP
1 parent a996c07 commit 21d9057

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/frequenz/sdk/microgrid/_power_distributing/_component_status/_battery_status_tracker.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,7 @@ def _is_inverter_state_correct(self, msg: InverterData) -> bool:
402402
# component to be working if any of its states is valid. Maybe we need to switch
403403
# to the negative and consider a component not working if is in any known
404404
# invalid state instead.
405-
if not (component_states & valid_states):
405+
if not component_states & valid_states:
406406
if self._last_status == ComponentStatusEnum.WORKING:
407407
_logger.warning(
408408
"Inverter %d has invalid states: %s",
@@ -430,7 +430,7 @@ def _is_battery_state_correct(self, msg: BatteryData) -> bool:
430430
# component to be working if any of its states is valid. Maybe we need to switch
431431
# to the negative and consider a component not working if is in any known
432432
# invalid state instead.
433-
if not (component_states & valid_states):
433+
if not component_states & valid_states:
434434
if self._last_status == ComponentStatusEnum.WORKING:
435435
_logger.warning(
436436
"Battery %d has invalid states: %s, expected: %s",

0 commit comments

Comments
 (0)