@@ -271,7 +271,7 @@ def update_pulse_counter(
271271 self , pulses_consumed : int , pulses_produced : int , timestamp : datetime
272272 ) -> None :
273273 """Update pulse counter.
274-
274+
275275 Both device consumption and production counters reset after the beginning of a new hour.
276276 """
277277 self ._cons_pulsecounter_reset = False
@@ -287,7 +287,7 @@ def update_pulse_counter(
287287
288288 if (
289289 self ._pulses_production is not None
290- and self ._pulses_production < pulses_produced
290+ and self ._pulses_production < pulses_produced
291291 ):
292292 self ._prod_pulsecounter_reset = True
293293 _LOGGER .debug ("update_pulse_counter | production pulses reset" )
@@ -313,9 +313,9 @@ def update_pulse_counter(
313313
314314 def _update_rollover (self ) -> None :
315315 """Update rollover states.
316-
316+
317317 When the last found timestamp is outside the interval `_last_log_timestamp`
318- to `_next_log_timestamp` the pulses should not be counted as part of the
318+ to `_next_log_timestamp` the pulses should not be counted as part of the
319319 ongoing collection-interval.
320320 """
321321 if self ._log_addresses_missing is not None and self ._log_addresses_missing :
@@ -341,7 +341,7 @@ def _detect_rollover(
341341 next_log_timestamp : datetime | None ,
342342 is_consumption = True ,
343343 ) -> bool :
344- """Helper function for _update_rollover() ."""
344+ """Detect rollover based on timestamp comparisons ."""
345345
346346 if (
347347 self ._pulses_timestamp is not None
0 commit comments