refactor: season → open, edition-scoped vocabulary (#364) #471
No reviewers
Labels
No labels
area: build
area: ci
area: compare
area: data
area: engine
area: model
area: provenance
area: rite
area: validation
backport
blocked
breaking
confirmed
dependencies
duplicate
epic
github_actions
invalid
needs-info
needs-triage
php
priority: high
priority: low
priority: medium
regression
type: bug
type: chore
type: correction
type: docs
type: enhancement
type: feature
type: fix
type: perf
type: refactor
type: security
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Directorium/Core!471
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feature/364-season-vocabulary"
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?
What & why
Reclassifies the output-contract
seasonfield from a closed 8-member enum to an open, edition-scoped vocabulary, before the 1.0 contract freeze (#90, which this blocks). A closed set could never admit the Novus Ordo'sordinary-timewithout a major bump — the exact breaking change v1 exists to prevent — so freezing it as closed would wall 1962↔NO calendar comparison behind a v2.Design (per #364)
advent/lent/eastertidemean the same thing across editions, so the comparison diff aligns by token with no per-edition remapping; the namespace is the existingeditionfield.ordinary-time— a minor bump.Changes
src/Temporal/SeasonVocabulary.php— the registry: the open union (derived from the subsets, no second list to drift) + per-edition subsets keyed byRubricSystemURN. Single source of truthSeasonvalidates against.src/Temporal/Season.php—fromString()now validates via the registry (was a hardcodedconst VALID); newforEdition($token, $editionUrn)enforces an edition's subset. Docblock updated.docs/design/season-vocabulary.md(new) — registry, shared-token rule, per-edition subsets, the open-enum (minor) bump rule; illustrative NO row explicitly marked not registered / documentation only (clean-room).output-contract.mdlinks it.SeasonVocabularyTest(union==traditional, per-edition subsets, openness, unknown-edition throw) +forEditioncases onSeasonTest.Verification
lint✅ ·analyse✅ ([OK] No errors) ·test✅ 1011 tests, 143,873 assertions (1 skipped = the live-oracle sweep).const VALIDand the newtokens()are the same 8 tokens in the same order. The golden contract fixtures are in the passing suite.seasonexists (corpus schema field is a freeslug; no other PHP validator).@throwsnote, both fixed in this PR).Closes #364.