Repository navigation
feat: assert the $schema a manifest declares - #104
Merged
Merged
Conversation
Two manifests point at a JSON Schema and nothing ever read those pointers. Measured 2026-10-29, both URLs resolve to 404 — each 301s to www.anthropic.com and stops there. Six candidate replacements were probed; none returned a real schema (one answers 200 with a 296 KB HTML error page). The assertion therefore judges only what the repository can decide alone: the value is non-empty, it is an absolute https URL, the key appears once per file, and the set of files declaring one is pinned. Reachability is deliberately not checked — every other check in this file is offline, and a curl would redden on a DNS blip while staying wrong the moment the remote moved. It lives partly in smoke-test because hooks/* is in the smoke path set while the release job runs only on manifest/CHANGELOG/README changes: a change to release-check alone would otherwise never execute the new check in CI. Four mutations each reddened their own named case; restoring the file byte-identically returns the suite to ALL SMOKE PASSED.
hkwuks
added a commit
that referenced
this pull request
Oct 30, 2026
The task landed in PR #104 and its three Steps were already `done`; only the archive never ran, so the directory sat under `TaskFlowDocs/` and the Todo entry still read `in_progress` with a Next action asking for a v2 re-approval that had already happened on 2026-10-29 20:50. `hooks/task complete` moves the task directory to `achieved/`, reduces the Todo entry to the five fields triage still needs, and sets both documents to `completed`. No code changes: everything this task shipped is already on `main` in ae4c60d.
8 of 9 tasks
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.
Summary
hooks/release-checknow reads the$schemaa manifest declares. Nothing had ever inspected those pointers, and measured 2026-10-29 both of this repository's resolve to 404 — each301s towww.anthropic.com/...and stops there.The assertion judges only what the repository can decide by itself:
""and a non-string are reported separately — they are different mistakes)httpsURLReachability is deliberately not checked. Every other check in this file is offline; a
curlhere would redden on a DNS blip and would still be wrong the moment the remote moved — which is how these two went unnoticed. The pin is enforced only once something declares, so a repository that has not adopted$schemais not told it dropped one it never had.TaskFlow traceability
TaskFlowDocs/2026-10-29-schema-check/(v2)hooks/release-check(the new section),hooks/smoke-test(six fixture cases appended to the section that already drivesrelease-check),CHANGELOG.mdmainVerification
Hooksworkflow reports pass for this branch — run to be linked once CI reportsgit diff --checkbash hooks/release-check .→STATUS: pass, exit 0bash hooks/smoke-test→ALL SMOKE PASSEDMutation results
Each mutation breaks one condition; the case that names it goes red, and no other does.
FAIL empty $schema acceptedhttpstestFAIL non-https $schema accepted: http://example.invalid/x.schema.jsonFAIL duplicate $schema acceptedFAIL a pinned declaration was dropped silentlyALL SMOKE PASSED,diff -qcleanReview boundaries
TaskFlowDocs/todo.mddiff is this task's own intake and promoteWhy the check also lives in
smoke-testhooks/*is in the smoke path set, while thereleasejob runs only when a manifest,CHANGELOG.mdor a README changes. A change torelease-checkalone would therefore never execute the new check in CI.hooks/smoke-testalready drivesrelease-checkfrom a fixture (== release-check catches version drift and a bad marketplace pin ==), so the new cases are appended there rather than introducing a second mechanism.Known limitations
$schema(.codebuddy-plugin/*,.codex-plugin/plugin.json,package.json). Whether that is intentional is not decided here; the pin records the current set so a change either way is visible.release-checkstill runs in CI only when a manifest,CHANGELOG.mdor a README changes. The smoke wiring makes the check exercised on every hook change, but the real repository's own manifests are only read by thereleasejob.