Skip to content

v1.3.0 — HA weather entity spec conformance

Choose a tag to compare

@ivanlee1007 ivanlee1007 released this 27 Mar 01:48
· 61 commits to master since this release

HA Weather Entity Spec Conformance

weather.py

  • NEW native_uv_index — UV index now properly exposed as entity attribute
  • NEW native_precipitation — total precipitation (rain + snow) in mm
  • NEW native_rain — rain amount in mm
  • NEW native_snow — snow amount in mm
  • FIX _async_forecast_daily() now returns daily forecast separately
  • FIX _async_forecast_hourly() now returns hourly forecast separately
  • DEPRECATE direct .forecast property — use _async_forecast_daily/hourly() instead
  • Improved type hints and code clarity

weather_update_coordinator.py

  • FIX Forecast entries now return proper Forecast dataclass (not dict)
  • FIX datetime stored as datetime object (not ISO string) per HA spec
  • NEW daily and hourly forecasts built and stored separately as list[Forecast]
  • NEW _build_forecast() handles malformed API entries gracefully

const.py

  • NEW ATTR_API_FORECAST_DAILY and ATTR_API_FORECAST_HOURLY constants