Skip to content

Fix server crash on sub-monthly diagnostics with registered obs#73

Open
AlexisRenchon wants to merge 2 commits into
mainfrom
ar/fix-submonthly-aggregation
Open

Fix server crash on sub-monthly diagnostics with registered obs#73
AlexisRenchon wants to merge 2 commits into
mainfrom
ar/fix-submonthly-aggregation

Conversation

@AlexisRenchon

Copy link
Copy Markdown
Member

Deploying #72 crashed the server during startup precompute: the AMIP atmos output also carries a daily pr file; available_levels advertises :monthly for daily-native data, but aggregate_var only implemented :native/:seasonal/:annualUnknown aggregation level: monthlyserve_apps.jl aborted (and Restart=no left the app down).

Three-part fix:

  1. aggregate_var implements :monthly and :daily ((year, month) and calendar-day bins, NaN-aware like the existing levels), with aggregation_label entries and regression tests asserting every advertised level aggregates without throwing.
  2. Coupled precompute uses the component's own SimDir (pruned to 1M, read from output_active, i.e. what discover_components built and the UI serves) instead of re-scanning the raw component folder. This also stops the pre-existing Time dimension is not in non-decreasing order load failures from stale loose files, and makes precompute fingerprints identical to the runtime lookups in events.jl (they were computed from different file sets before).
  3. Per-entry try/catch in precompute — precompute is an optimization; a failing entry is warned and skipped, never fatal.

Validation: full suite passes (125 tests, 8 new).

🤖 Generated with Claude Code

AlexisRenchon and others added 2 commits July 2, 2026 11:11
Deploying #72 crashed the server during cache precompute: the AMIP atmos
output also carries a daily pr file, available_levels advertises :monthly
for daily-native data, and aggregate_var only implemented
:native/:seasonal/:annual — the error aborted serve_apps at startup.

Three-part fix:
- aggregate_var implements :monthly ((year, month) bins) and :daily
  (calendar-day bins), with labels and regression tests
- coupled-mode precompute_dashboard_cache now takes the component's own
  SimDir (pruned to 1M, read from output_active) instead of re-scanning the
  raw folder, so it covers exactly what the UI serves, stops tripping over
  stale loose files ("Time dimension is not in non-decreasing order"), and
  produces fingerprints that match runtime lookups
- per-entry try/catch in precompute: a failed entry is warned and skipped,
  never fatal — the dashboard falls back to live computation on a miss

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The default_gpcp_obs docstring cross-references to_display_units with @ref;
Documenter treats an unresolved cross-reference as fatal, which broke the
docs build.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant