Skip to content

feat: adaptive polling frequency for minutely precipitation #565

@Orinks

Description

@Orinks

Description

Currently AW fetches minutely precipitation data on the same interval as the regular weather poll (e.g. every 30 minutes). This means short rain events can be completely missed between polls.

Proposed Solution

When the hourly forecast shows any precipitation probability above a threshold (e.g. 30%+) in the next few hours, increase the minutely polling frequency to every 5-10 minutes. When conditions are clear, keep the normal interval to conserve API calls.

This is similar to how Apple Weather uses geofence-triggered updates during stable conditions but increases frequency when precipitation is likely.

Implementation Notes

  • Check hourly forecast precipProbability during regular polls
  • If probability > threshold, switch to a shorter minutely poll interval
  • Track API call budget (free tier: 10k/month = ~13/hour if constant, plenty for 5-min intervals during rain windows)
  • Revert to normal interval when hourly forecast clears
  • Could also trigger faster polling when PW minutely summary contains precipitation keywords

Impact

Significantly reduces missed rain notifications — the #1 gap vs Alexa/AccuWeather

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions