Skip to content

fix(schema): x-schema-version 1.20 and a ledger gate that fails a change without a bump and a bump without a change; release 0.42.2 (#279) - #280

Merged
astrapi69 merged 3 commits into
mainfrom
fix/279-schema-version-gate
Oct 22, 2026
Merged

astrapi69 merged 3 commits into
mainfrom
fix/279-schema-version-gate

Conversation

@astrapi69

Copy link
Copy Markdown
Owner

Closes #279

What

0.42.1 changed a schema description and kept x-schema-version at 1.19, although docs/lesson-format.md (since #139) says the counter bumps on every change to the definition, description-only edits included. This release:

  1. Moves both schema files to 1.20 (lockstep), with 0.42.1's content. quality-rules.json and grading-presets.json carry the new $schema-version. The baselines and generated modules are regenerated (make sync-types, generate-schema-diagrams.mjs).

  2. Adds a ledger gate in both directions. src/__fixtures__/schema-baseline/schema-version-ledger.json maps each version to the digest of the schema set: both files parsed, $id and x-schema-version removed, keys sorted (scripts/schema-version-ledger.mjs). src/schema-version-ledger.test.ts runs in npm test, so in make release-check, and fails when:

    • the content changes under an unchanged number;
    • a number rises without a change, both with and without a ledger row for it;
    • the two files are out of lockstep;
    • two rows share a digest.

    The seeded probes run on a ledger that is consistent by construction, so they prove the gate can fail whatever the repository's own state is. RED before the bump, on this repository: the schema content changed but x-schema-version is still 1.19. GREEN after.

  3. Docs name no version where none is needed. README, concepts.md, architecture.md, comparative-analysis.md and the three blog posts in both languages no longer state the current schema or package version.

    • A Mermaid node in comparative-analysis.md still said "schema 1.15", four versions on, out of reach of the version-claims gate, which reads only "currently ..." phrasings.
    • The manifest schema_version default in lesson-format.md stays: authors need it, and the version-claims gate needs one claim to prove it does not scan blind.
    • lesson-format.md records v1.20 and 0.42.1's slip in the counter history, and CONTRIBUTING names the ledger row in the schema-change steps.
  4. CHANGELOG: a 0.42.2 section, and an explicit correction of 0.42.1's "x-schema-version stays 1.19".

History, measured over every release tag

Content that changed under an unchanged number happened seven times. Five predate the rule: 0.7.0, 0.8.1, 0.8.2, 0.14.0, 0.20.0. Two came after it: 0.24.1 (1.14) and 0.42.1 (1.19). A number that rose without a change never happened. The ledger starts at 1.19 (0.42.0's content) and 1.20; older versions had several contents and are documented, not recorded.

Gates

  • make release-check: green, 78 test files, 2089 tests.
  • make sync-types-check: green.
  • make prose-check: OK.
  • npm run docs:api:check: OK.

Docs audit (.claude/rules/release.md)

  • schema: x-schema-version must move with every content change (0.42.1 and 0.24.1 did not); gate both directions #279: every current-version claim was searched in README, CONTRIBUTING, docs/ and both blog languages: the gated phrasings with the docs-version-claims test, the ungated ones with a scan for a version number next to "current, now, today, pin, latest, aktuell, jetzt".
    • Removed: the claims listed above.
    • Kept as dated history: architecture's "Closed on ... all ten content repos pin 0.29.0" and similar entries, the blog sections about the state then, the document's own version in comparative-analysis.md, and "(0.38.0, engine#246)" in lesson-format.md.
  • Downstream:
    • adaptive-learner re-pins to 0.42.2 (its PR #3832 moves from 0.42.1 to 0.42.2).
    • The content repos' daily engine-currency.yml (05:30 UTC) sees the new latest tomorrow and opens its issue. They re-pin after that, in one pass.

🤖 Generated with Claude Code

astrapisixtynine and others added 3 commits October 22, 2026 13:34
… gate in both directions (#279)

0.42.1 changed the ExerciseVariable description under 1.19, against the
rule that a description-only edit bumps x-schema-version too. Both schema
files move to 1.20 (lockstep), quality-rules.json and grading-presets.json
follow, the baselines and generated modules are regenerated.

The new ledger (src/__fixtures__/schema-baseline/schema-version-ledger.json)
maps each version to the digest of the schema set's content without $id
and x-schema-version. src/schema-version-ledger.test.ts fails on a change
without a bump, a bump without a change, files out of lockstep and two
rows with one digest; seeded probes run on a ledger consistent by
construction. RED before the bump, on this repository: "the schema
content changed but x-schema-version is still 1.19".

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…v1.20 and the ledger (#279)

README, concepts, architecture, comparative-analysis and the three blog
posts in both languages no longer state the current schema or package
version; the schema file does. A Mermaid node in comparative-analysis
still said "schema 1.15" four versions on, out of the version-claims
gate's reach. The manifest schema_version default in lesson-format.md
stays: authors need it and it keeps that gate from scanning blind.
lesson-format.md records v1.20 and 0.42.1's slip in the counter history;
CONTRIBUTING names the ledger row in the schema-change steps.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
CHANGELOG section for 0.42.2 and an explicit correction of 0.42.1's "x-schema-version stays 1.19". make release-check, prose-check and docs:api:check are green.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@astrapi69
astrapi69 merged commit 49a9396 into main Oct 22, 2026
4 checks passed
@astrapi69
astrapi69 deleted the fix/279-schema-version-gate branch October 22, 2026 11:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

schema: x-schema-version must move with every content change (0.42.1 and 0.24.1 did not); gate both directions

2 participants