Repository navigation
fix(scaffold): discover the Ambrosian sanctorale per edition (#101) - #103
Merged
Merged
Conversation
API#963 gave the Ambrosian sanctorale inventory ids a missal-edition segment (`sanctorale:ambrosian:EDITIO_TYPICA_2024` and its `:i18n`), but inventoryIdsForCalendar() still composed the edition-less pair. The API no longer advertised it, so buildSourceDataChecks() warned and skipped both, and every Ambrosian scaffold silently stopped checking its sanctorale. Nothing in /calendars names the editions, so the non-Roman sanctorale is now discovered from the /validations inventory by prefix, the same way the rite's lectionary sections already are; composing it would mean hardcoding an edition list that grows as editions gain data (API#957). The Roman sanctorale:roman:* family stays composed from national metadata. Tests: the composed Ambrosian expectations drop the sanctorale pair; rite-selection pins the edition/i18n pairing like the Roman missals; a new spec checks every composed Ambrosian rite-level id against the live inventory and that at least one edition is there to be discovered. Closes #101 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 34 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #101
Problem
API#963 (merged 2026-09-02) added the missal edition to the Ambrosian sanctorale inventory ids:
sanctorale:ambrosiansanctorale:ambrosian:EDITIO_TYPICA_2024sanctorale:ambrosian:i18nsanctorale:ambrosian:EDITIO_TYPICA_2024:i18ninventoryIdsForCalendar()still composed the edition-less pair. The API no longer advertises it, sobuildSourceDataChecks()logged a warning and skipped both. Every Ambrosian scaffold had silently stopped checking the Ambrosian sanctorale. Only the E2E run caught it (rite-selection.spec.ts:182), on #102, the first run of the workflow since 2026-08-29.Fix
Nothing in
/calendarsnames the Ambrosian editions, so the non-Roman sanctorale is now discovered from the/validationsinventory by prefix (sanctorale:{rite}:), the same way the rite's lectionary sections already are. This follows the rule the code documents: compose what calendar metadata implies, and discover from the inventory what it does not. Hardcoding the edition would break again when 1976 gains data (API#957).The Roman
sanctorale:roman:*family stays composed from national metadata. Discovering it would put every nation's missals on every Roman scaffold.CONDITIONAL_INVENTORY_IDis unchanged. Comments that citedsanctorale:ambrosian:i18nas a live id now explain that it is the pre-#963 shape.Tests
ws-protocol.spec.ts: the composed Ambrosian expectations (rite-level and diocesan) drop the sanctorale pair.ws-protocol.spec.ts: a new spec checks every composed Ambrosian rite-level id against the live/validations, and that at least onesanctorale:ambrosian:{edition}is there to be discovered. The existing "every composed id is advertised" spec only covered a Roman scope, which is why this drift went unnoticed.rite-selection.spec.ts: pins the Ambrosian edition/-i18ncard pairing, in the same way as the Roman missals, so a new edition needs no edit.resources-rite.spec.tsand thewsProtocol.jsdocblock: id spelling corrected toEDITIO_TYPICA_2024.Issue #101 also suggested deriving the expected-id arrays from
/validations. Those arrays are the expected output of a pure function, so they stay literal. The live-inventory comparison is in the new spec instead.Verification
npm run typecheckand eslint on the changed JS pass.development,inventoryIdsForCalendar()composes only advertised ids for the Ambrosian rite-level scope. The discovery filter findssanctorale:ambrosian:EDITIO_TYPICA_2024and its:i18n, and finds nosanctorale:roman:*under a Roman scope.Once this is merged, #102 (PIE) can be rebased onto it and should go green.
🤖 Generated with Claude Code