Eclipse events need an ephemeris and a visibility model, not a date table #126
Labels
No labels
area/ai
area/backend
area/frontend
area/infra
area/scheduler
area/wled
good-first-issue
priority/high
priority/low
priority/medium
type/bug
type/chore
type/ci-cd
type/docs
type/feature
type/qa
v1.0.0
v1.1.0
v1.2.0
v2.0.0
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rbrooks/Iris-WLED#126
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Split from #20, which delivered meteor showers, named full moons and the optional aurora layer. Eclipses were the remaining acceptance-criterion item and they are a materially different problem from the other two.
Why they did not go in with the rest
They are not computable from the current dependencies.
astralgives sun and moon positions and phase — enough for full moons, which is why those are computed rather than tabulated — but it has no eclipse function. The same gapdocs/troubleshooting.mdalready documents for solstices and equinoxes.A date table would be the wrong shape here. Solstices are tabulated (
ASTRONOMICAL_DATES, 2020–2035) and #61 exists precisely because that table silently runs out. Adding eclipses the same way would add a second thing to the horizon warning for a payoff that is smaller than it looks, because:Only visible eclipses are worth lighting for. A total lunar eclipse over the Indian Ocean means nothing to a roofline in Texas. Visibility depends on the observer's latitude and longitude and on the eclipse's path — for a solar eclipse, whether it is total, partial or invisible varies over a few hundred kilometres. An event that fires for every eclipse worldwide would be wrong most of the time, and marking a "partial eclipse, 12% obscured, below the horizon" is worse than not marking it.
So the useful version needs both a source of eclipse circumstances and a per-observer visibility calculation, which is a real ephemeris dependency rather than a lookup.
What doing it properly looks like
skyfieldis the usual choice and can compute both eclipse circumstances and local visibility. Note this is a heavier dependency than anything currently in the image, which #60 deliberately slimmed; worth weighing against the payoff of a handful of events a year.LATITUDE/LONGITUDE, and only create an event when the eclipse is actually visible from there and above the horizon.The same dependency would also let the solstice and equinox tables be replaced by computation, closing #61's horizon warning for four of its six events — which may be the stronger argument for taking it on.
Related