Skip to content

v1.3.1 — Hardening (dual-AI adversarial review)

Latest

Choose a tag to compare

@CaputoDavide93 CaputoDavide93 released this 07 Jul 14:08

Hardening release from a dual-AI (Claude + Codex) adversarial review focused on HA-core compatibility and robustness. Also fixes the weekly hassfest failure.

Fixed

  • Cost sensor state classMONETARY device class only permits TOTAL; was TOTAL_INCREASING, which HA core rejects for long-term statistics.
  • Stale-poll accumulator poisoning — the energy and cost accumulator sensors kept integrating power across failed coordinator polls, manufacturing phantom kWh from stale readings. They now skip integration and resync their clock while the poll is failing.
  • API URL guards — 10 assert <url> is not None sites in api.py replaced with a typed _require_url() raising MixergyConnectionError; AssertionError escaped the error taxonomy and disappears under python -O.
  • Options flow cross-field validationno_water_threshold can no longer be set at or above low_water_threshold; the form re-shows with a translated error (en/de/fr/it).
  • services.yaml schema drift — removed area: {} and device: filters from service target: blocks; hassfest now only accepts entity: filters.

Added

  • 4 regression tests covering the fixes above (76 total).

🤖 Generated with Claude Code