v1.2.13-beta.2
Pre-releaseRelease v1.2.13-beta.2
Release Date: 2026-02-24
Type: Beta release - Fixes sync mechanism that failed to prevent energy oscillation.
What's Changed (since v1.2.13-beta.1)
Fixed
-
Sync timeout counter poisoned by idle polls - The beta.1 sync mechanism's timeout counter
incremented on every poll, including idle polls where neitherenergia_prodottanor
energia_immessachanged. During the ~14 minutes between Alfa firmware register updates
(when both values are static), the counter cycled through 0-1-2(timeout)-0-1-2... When the
firmware finally updated one sensor, the counter could already be near the timeout threshold,
causing it to fire immediately and calculateprodotta - immessawith desynchronized values.Root cause: The
elsebranch in_calculate_derived_values()treated "one sensor changed"
and "neither changed" identically — both incremented the timeout counter.Fix: Split into two branches:
- Exactly one changed — increment counter, wait for the other (with timeout fallback)
- Neither changed — reset counter to 0 (no new data to act on)
This ensures the counter is always at 0 when the first actual firmware update arrives,
giving the second sensor a full timeout window to catch up.
Testing Focus
After deploying this update:
- Monitor
sensor.alfa_energy_self_consumedduring peak solar production hours - The history graph should show smooth monotonic increase — NO sawtooth dips
- Utility meters tracking autoconsumption should not show sudden jumps
Technical Details
- Files changed:
api.py(sync logic),test_api.py(updated + regression test) - Test coverage: 98%
- CI: All 3 workflows passing (Lint, Tests, Validate)
Full Changelog:
compare/v1.2.13-beta.1...v1.2.13-beta.2