diff --git a/config/runtime.exs b/config/runtime.exs index f2578331..c317dba6 100644 --- a/config/runtime.exs +++ b/config/runtime.exs @@ -304,7 +304,13 @@ if config_env() == :prod do {"*/10 * * * *", Microwaveprop.Workers.IonosphereFetchWorker}, # NOAA SWPC: Kp / GOES X-ray at 1-min cadence, F10.7 hourly. # 5-min poll balances freshness vs request volume. - {"*/5 * * * *", Microwaveprop.Workers.SpaceWeatherFetchWorker} + {"*/5 * * * *", Microwaveprop.Workers.SpaceWeatherFetchWorker}, + # Recompute hrrr_climatology nightly from the hrrr_profiles + # archive. Idempotent — UPSERT on (lat, lon, month, hour) — and + # cheap enough to run daily so the table self-heals if a + # deploy clears it or new profiles need to fold into the means. + # 02:30 UTC sits inside the quiet pre-NARR/HRRR ingestion gap. + {"30 2 * * *", Microwaveprop.Workers.AdminTaskWorker, args: %{"task" => "climatology"}} ]} base_plugins = [ diff --git a/scripts/recalibrate_algo.py b/scripts/recalibrate_algo.py index 7b86a4d9..17f0bbd5 100755 --- a/scripts/recalibrate_algo.py +++ b/scripts/recalibrate_algo.py @@ -343,7 +343,11 @@ DATA_GAP_RULES: list[dict] = [ "key": "hrrr_climatology_rows", "broken_when": lambda v: v == 0, "warn_when": lambda _v: False, - "remediation": "Run `mix hrrr_climatology` (see lib/mix/tasks/hrrr_climatology.ex).", + "remediation": ( + "Should self-heal within 24h via the daily 02:30Z cron that " + "runs AdminTaskWorker(task=climatology). If still 0 after a " + "day, check Oban dashboard for failed admin jobs." + ), }, { "key": "rtma_rows",