Validate MMED schedule data via the shared pre-commit hook (#54) - #26
Open
WestonVoglesonger wants to merge 2 commits into
Open
Validate MMED schedule data via the shared pre-commit hook (#54)#26WestonVoglesonger wants to merge 2 commits into
WestonVoglesonger wants to merge 2 commits into
Conversation
Adds MMED's own schedule data (_data/schedule/mmed/2025.yml, extracted from the live schedule wall) and a workflow that validates it by pulling in the shared composite action from the ICI3D.github.io submodule. MMED owns its data; the validation logic stays single-source in the theme repo. Depends on ICI3D/ICI3D.github.io#59 (the composite action) being merged and MMED's submodule pointer bumped to it. Verified locally: the shared validator reports 0 errors / 0 warnings on this data. Supersedes the earlier spike PR ICI3D#25 (which duplicated the tools/renderer here instead of pulling them from the theme).
Replaces the composite-action-via-submodule workflow with the distributed pre-commit hook from ICI3D.github.io: MMED pins the hook in .pre-commit-config.yaml and gets the same validation locally (pre-commit install) and in CI (pre-commit/action), with the schema and role vocabulary pulled in from the shared package (no vendoring). Instructor keys resolve against the shared people records from the ICI3D.github.io submodule via --people-dir, until MMED owns its own _data/team. Interim: the hook points at the fork branch until ICI3D/ICI3D.github.io#59 merges; then it flips to the upstream repo at the merge sha.
Author
|
@pearsonca reshaped this to consume the shared validator as a pinned pre-commit hook instead of a composite action through the submodule, so contributors run the same check locally, not just in CI.
Verified: 0 errors / 0 warnings on MMED's 2025 data against the 69 shared people records. Draft pending #59; the hook points at the fork branch for now and flips to upstream at the merge sha once #59 lands. |
WestonVoglesonger
marked this pull request as ready for review
July 27, 2026 15:03
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.
Makes MMED pull the shared schedule validator in as a pinned pre-commit hook, rather than vendoring its own copy. Reshaped to the Path A model: the validator, JSON Schema, and role vocabulary live once in
ICI3D.github.io(now packaged and exposed as a pre-commit hook), and MMED consumes them with no duplication and no per-clinic maintenance.What's here
_data/schedule/mmed/2025.yml— MMED's own schedule data (extracted from the live wall). MMED owns its data; it lives here, not in the shared theme..pre-commit-config.yaml— pins the sharedvalidate-schedulehook. Contributors get the same check locally on every commit (pip install pre-commit && pre-commit install), and it runs in CI viapre-commit/action, so local and CI validation are one source of truth..github/workflows/schedule-validate.yml— runs that same hook on push/PR. Checks out theICI3D.github.iosubmodule only for its shared people records (the hook's--people-dir), which is how instructor keys resolve today, the same records the Jekyll build reads.Why this shape (vs. the earlier composite-action version)
The schema and validator are pulled in by pre-commit, not by a submodule path, so contributors run the identical check locally before pushing (the original ask in #54), not only in CI. Nothing clinic-specific is maintained here beyond the data file and a few lines of config. A new clinic drops in the same
.pre-commit-config.yaml+ its own data.Verified locally
The shared validator reports 0 errors / 0 warnings on this data, resolving MMED's instructor keys against the 69 shared people records in the
ICI3D.github.iosubmodule. This is the exact path the hook runs.Draft — depends on the theme PR
The hook currently points at the fork branch carrying the packaged validator (
WestonVoglesonger/ICI3D.github.io, pinned by sha), because ICI3D/ICI3D.github.io#59 is not merged yet. Once #59 merges, flip the hook'srepo:toICI3D/ICI3D.github.ioandrev:to the merge sha/tag. Until then this is a working preview against the fork.Follow-up (not in this PR)
Rendering still comes through the submodule. Moving MMED's rendering to
remote_theme: ICI3D/ICI3D.github.io(dropping the submodule, and having MMED own its_data/team) is a separate, site-build-affecting change and the #56 topology call. This PR deliberately touches only the validation channel, which is safe and independent.Supersedes #25
Closes out the earlier spike (#25), which put the tools/schema/renderer in MMED instead of pulling them from the theme.
Part of #54 / epic #58.