diff --git a/packages/control/phase_switch.py b/packages/control/phase_switch.py index afd19ef4e2..4b4df1a51e 100644 --- a/packages/control/phase_switch.py +++ b/packages/control/phase_switch.py @@ -45,4 +45,4 @@ def _perform_phase_switch(chargepoint_module: AbstractChargepoint, phases: int, def phase_switch_thread_alive(cp_num): - is_thread_alive(f"phase switch cp{cp_num}") + return is_thread_alive(f"phase switch cp{cp_num}") diff --git a/packages/modules/chargepoints/mqtt/chargepoint_module.py b/packages/modules/chargepoints/mqtt/chargepoint_module.py index 46df6b6ea2..65c7af517b 100644 --- a/packages/modules/chargepoints/mqtt/chargepoint_module.py +++ b/packages/modules/chargepoints/mqtt/chargepoint_module.py @@ -1,5 +1,6 @@ import logging +from helpermodules.utils.error_counter import CP_ERROR, ErrorTimerContext from modules.chargepoints.mqtt.config import Mqtt from modules.common.abstract_chargepoint import AbstractChargepoint from modules.common.abstract_device import DeviceDescriptor @@ -15,7 +16,8 @@ def __init__(self, config: Mqtt) -> None: self.fault_state = FaultState(ComponentInfo( self.config.id, "Ladepunkt", "chargepoint")) - self.a = 5 + self.client_error_context = ErrorTimerContext( + f"openWB/set/chargepoint/{self.config.id}/get/error_timestamp", CP_ERROR, hide_exception=True) def set_current(self, current: float) -> None: with SingleComponentUpdateContext(self.fault_state):