You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
refactor: Decompose coordinator and add event-driven updates
Decompose Coordinator:
- Extract valve_manager.py: Valve control, anti-cycling, maintenance
- Extract heater_controller.py: Flow temperature calculation and control
- Extract zone_logic.py: Setpoint calculation and adaptive start utilities
- Coordinator reduced from 1387 to 1124 lines (~19% reduction)
Event-Driven Updates:
- Add state_debouncer.py: Debounced state change tracking
- Window sensor changes now trigger immediate zone updates (30s debounce)
- Added _update_single_zone for partial zone updates
- State debouncer properly cleans up listeners on shutdown
Changes:
- Module imports added to coordinator
- HeaterController and ValveManager instantiated in __init__
- StateDebouncer integrated with window sensor tracking
- async_shutdown updated to clean up debouncer listeners
- Service handler fixed for updated _perform_valve_maintenance signature
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>