Resolver floor: resolveYear(1583) throws (reaches back to pre-floor 1582) #415

Open
opened 2026-07-02 15:06:59 +00:00 by manlycucumber · 0 comments
manlycucumber commented 2026-07-02 15:06:59 +00:00 (Migrated from github.com)

Problem

DayResolver::resolveYear(1583) throws — the resolver reaches back for the trailing Christmas cycle that bleeds into January (ChristmasCycle::forYear($year - 1)), and for 1583 that is forYear(1582), below the engine's Gregorian floor (Computus::GREGORIAN_REFORM_YEAR = 1583). So although 1583 is the advertised first Gregorian year, the whole-year resolver's effective floor is 1584.

Surfaced while building the golden-fixture safety gate (#365), which consequently freezes 1584–2200. Documented in KNOWN-LIMITATIONS.md.

Options

  • Special-case January 1583 so the days belonging to the Advent/Christmas cycle begun in (Gregorian) December 1582 resolve, treating 1582's post-reform December as in scope.
  • Or accept 1584 as the resolver floor and keep 1583 documented as out of range (querying a 1583 date would then raise a clear, intentional error rather than an internal one).

Acceptance criteria

  • day()/resolveYear() for 1583 either resolves correctly or fails with a clear, intentional boundary error (not an internal ChristmasCycle exception).
  • Decision recorded; KNOWN-LIMITATIONS.md updated; if 1583 becomes resolvable, the golden fixture (#365) is extended to 1583 and re-frozen.

Notes

Low priority, no downstream dependency (no consumer queries 1583). Cheap to keep tracked.

## Problem `DayResolver::resolveYear(1583)` throws — the resolver reaches back for the trailing Christmas cycle that bleeds into January (`ChristmasCycle::forYear($year - 1)`), and for 1583 that is `forYear(1582)`, below the engine's Gregorian floor (`Computus::GREGORIAN_REFORM_YEAR = 1583`). So although 1583 is the advertised first Gregorian year, the *whole-year* resolver's effective floor is **1584**. Surfaced while building the golden-fixture safety gate (#365), which consequently freezes **1584–2200**. Documented in `KNOWN-LIMITATIONS.md`. ## Options - Special-case January 1583 so the days belonging to the Advent/Christmas cycle begun in (Gregorian) December 1582 resolve, treating 1582's post-reform December as in scope. - Or accept 1584 as the resolver floor and keep 1583 documented as out of range (querying a 1583 date would then raise a clear, intentional error rather than an internal one). ## Acceptance criteria - [ ] `day()`/`resolveYear()` for 1583 either resolves correctly or fails with a clear, intentional boundary error (not an internal `ChristmasCycle` exception). - [ ] Decision recorded; `KNOWN-LIMITATIONS.md` updated; if 1583 becomes resolvable, the golden fixture (#365) is extended to 1583 and re-frozen. ## Notes Low priority, no downstream dependency (no consumer queries 1583). Cheap to keep tracked.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Directorium/Core#415
No description provided.