PropagationGridWorker hard-coded `now-2h` for run_time selection on the conservative theory that NOAA always finishes publishing within two hours. In practice f18 is on the mirror by HH:55–HH:00 of the next hour, so the cron at HH:05 was always picking a cycle that was already an hour stale. `HrrrClient.cycle_available?/1` HEADs the wrfprsf18 idx (the slowest file in the cycle) — a 200 means every earlier forecast hour is also on disk. `pick_run_time/1` probes `now-1h` first; if the probe returns true we use that cycle, otherwise we fall back to the existing `now-2h` slot. Test hook via :hrrr_cycle_available_fn env keeps the behaviour fully exercisable without hitting NOAA. End-to-end: weather/score data lag drops from ~2 h to ~1 h on every hour where NOAA delivers on time. The fallback path keeps the chain running on slow-publish hours. |
||
|---|---|---|
| .. | ||
| microwaveprop | ||
| microwaveprop_web | ||
| mix/tasks | ||
| microwaveprop.ex | ||
| microwaveprop_web.ex | ||