github jasonacox/pypowerwall v0.23.2
v0.23.2 - Energy Counter and Error Handling Fixes

50 minutes ago

v0.23.2 - Energy Counter and Error Handling Fixes

Three fixes: one from @wit3 (Salvatore Scalzi), found on his Powerwall 3 with a Backup Gateway 2, and two from new contributor @kochj23 (Jordan Koch). Thank you both!

  • fix(tedapi): the lifetime energy_imported / energy_exported values in /api/meters/aggregates no longer drop to 0 for one poll when a fetch of the gateway's local API fails. The failed fetch now serves the last good payload, as the 5-minute retry backoff already did. Home Assistant read the N → 0 → N dip as a meter reset and counted a Powerwall 3's whole battery lifetime (about 4.6 MWh charged, 4.5 MWh discharged) as new energy. Gateways where the endpoint has never answered still get 0s. (#463, follow-up to #221)
  • fix: grid_status() re-raises the backend's exception again. Its error log called type(e), which the deprecated type argument shadows, so callers got a TypeError and the log line was never written. (#464)
  • fix(local): a failed re-login after an expired session (HTTP 401/403) no longer raises out of poll() / post(). Reads such as level() and power() return None and log the cause, as the read contract requires. authenticate() still raises, so connect() can fall back to another mode. (#465)
  • Library version bumped to 0.23.2

Proxy: jasonacox/pypowerwall:0.23.2t112 (amd64 and arm) — upgraded to pyPowerwall v0.23.2 (#467). See the proxy release notes for proxy-visible changes.

Install: pip install --upgrade pypowerwall==0.23.2 — PyPI


Contributors

Thanks to the community members who made this release possible:

  • @wit3 (Salvatore Scalzi) — found and diagnosed the lifetime-energy dip on his Powerwall 3 with a Backup Gateway 2, and wrote the fix with new unit tests (#463). His companion Home Assistant guard is jackrayner/ha-pypowerwall#112.
  • @kochj23 (Jordan Koch) — first contributions to the project: the grid_status() exception-shadowing fix (#464) and the local-mode failed re-login fix (#465), each with unit tests. Welcome, Jordan!
  • @jasonacox — release engineering and proxy t112 (#466, #467).
  • @jasonacox-sam (Sam) — reviewed and tested all three fixes.

Don't miss a new pypowerwall release

NewReleases is sending notifications on new releases.