From ba0adbaf3176ff753312d7052d0dc2795ac55dc9 Mon Sep 17 00:00:00 2001 From: Lukasz Kasprzak Date: Sat, 15 Aug 2026 00:50:16 +0200 Subject: ef(lectionary): a feria says the preceding Sunday's Mass Chain step 3. Guarded on weekday <> Sun: a Sunday reaching this branch would look up its own slug via days_since_sunday Sun = 0 and loop -- every other chain step consults data, this one consults a strictly earlier date, so that guard is the whole chain's termination argument. Reaches the Sunday by Date.add_days plus a fresh temporal_at call, never by string surgery on the day's own slug -- the slug shapes are genuinely inconsistent across seasons (ef-advent-sunday-1 vs ef-advent-1-monday, week number on opposite sides of the season name). Uses the preceding Sunday's TEMPORAL slug, never its observed one: the rubric is the preceding Sunday's Mass even in a year a feast displaced that Sunday from being observed (pinned: 2028-12-26, the Monday after a Vigil-displaced Advent IV Sunday, still takes Advent IV's Mass). Measured over the full 1583-9999 domain (temporal cycle only, no sanctoral contest): of 412 distinct temporal slugs, 305 carry no lectionary entry of their own; of the 304 that are feria (non-Sunday) slugs, step 3 alone resolves 297 of them via their preceding Sunday. The 7 that remain, plus the 1 uncovered Sunday slug itself (ef-holy-name-sunday), all trace to the same two missing lectionary entries (Holy Name Sunday and 30 December), not to eight independent gaps or a step-3 defect -- traced date-by-date, not merely counted. Day-level effect, 2005-2050 (full Precedence+Calendar pipeline, matching this project's existing differential window): 16807 days, 16531 resolved (98.36%), 276 still empty; step 3 alone accounts for 4503 of the resolved days, more than either step 1 or step 2. Warrant is the same class as step 2's, not a confirmed Missal citation: lectio hard-codes this shape as literal duplicated data on the four Advent ferias (Advent I's own readings copied onto the following Monday-Thursday) and leaves the rest of that same shape simply absent; step 3 turns the duplication into a rule. dune test --force: 344 tests, all green (was 340). --- lib/rites/rite_ef/lectionary_ef.mli | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'lib/rites/rite_ef/lectionary_ef.mli') diff --git a/lib/rites/rite_ef/lectionary_ef.mli b/lib/rites/rite_ef/lectionary_ef.mli index 65fbfe5..159fd57 100644 --- a/lib/rites/rite_ef/lectionary_ef.mli +++ b/lib/rites/rite_ef/lectionary_ef.mli @@ -20,10 +20,12 @@ open Colitur_kernel masking the gap in every test run). See the task report for the reproduction. - Steps 1 and 2 only (Task 4): the observed celebration's own proper, else - the day's own temporal slug in the lectionary. A day matching neither - gets [] for now -- the ferial fallback to the preceding Sunday (Task 5) - and the Commons (Task 6) are not built here. *) + Steps 1-3 (Tasks 4-5): the observed celebration's own proper, else the + day's own temporal slug in the lectionary, else -- for a weekday whose + own slug has no entry -- the preceding Sunday's temporal slug (never its + observed one; a Sunday guards against consulting itself and looping, + see [readings]'s own implementation comment). A day matching none of the + three gets [] for now -- the Commons (Task 6) are not built here. *) val readings : lectionary:Lectionary.t -> observed:Vocab_ef.rank Celebration.t -> -- cgit v1.3