Skip to content

Commit 175dc10

Browse files
committed
Add idea-text to update_pulse_counter() docstring
1 parent 145983c commit 175dc10

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

plugwise_usb/nodes/helpers/pulses.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,12 @@ def _collect_pulses_from_logs(
260260
def update_pulse_counter(
261261
self, pulses_consumed: int, pulses_produced: int, timestamp: datetime
262262
) -> None:
263-
"""Update pulse counter."""
263+
"""Update pulse counter.
264+
265+
Both consumption and production counters reset at the beginning of a new hour.
266+
IDEA: should we treat this event not as a rollover but as a counter reset?
267+
What should be the effect of this reset?
268+
"""
264269
self._pulses_timestamp = timestamp
265270
self._update_rollover()
266271
if not (self._rollover_consumption or self._rollover_production):

0 commit comments

Comments
 (0)