Skip to content

Dark Hours Calculation Fix - #318

Merged
chvvkumar merged 2 commits into
mainfrom
dev
Oct 13, 2026
Merged

chvvkumar merged 2 commits into
mainfrom
dev

Conversation

@chvvkumar

@chvvkumar chvvkumar commented Oct 13, 2026 •

Copy link
Copy Markdown
Owner

What's fixed

  • Fixed an issue preventing dark hours from being calculated reliably.

The app container has no outbound DNS, so astropy's IERS_Auto can never
download a fresh Earth-orientation table and always falls back to the copy
bundled with astropy-iers-data at image build. Once that copy's predictive
data passed 30 days old, any date beyond it raised ValueError, and because
backfill_dark_hours deliberately computes 35 days ahead, every run failed.

astro_night now configures astropy to skip the download and accept the aged
table. Dark hours only need the sun's altitude to a fraction of a degree,
and the bundled UT1-UTC predictions are good to milliseconds, so the computed
values are unchanged. Verified by reproducing the production error locally
with downloads disabled and comparing against the online baseline.

Users see the stats timeline efficiency keep rendering for the current month
and the recurring task_failure event in the job monitor goes away.
Improve Dark Hours Calculation Reliability
@github-actions github-actions Bot changed the title Dev Dark Hours Calculation Fix Oct 13, 2026
@chvvkumar
chvvkumar merged commit b4d00de into main Oct 13, 2026
2 checks passed
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