Skip to content

fix(release): declare the inventory schema version the release gate requires - #1685

Merged
FelixTJDietrich merged 1 commit into
mainfrom
fix/release-inventory-schema-version
Aug 31, 2026
Merged

fix(release): declare the inventory schema version the release gate requires#1685
FelixTJDietrich merged 1 commit into
mainfrom
fix/release-inventory-schema-version

Conversation

@FelixTJDietrich

@FelixTJDietrich FelixTJDietrich commented Aug 31, 2026

Copy link
Copy Markdown
Collaborator

Description

The v0.75.0 release cut its tag, then tag-images failed with release image inventory is malformed.

scripts/verify-release-evidence.ts (introduced in #1628) requires schemaVersion === 1 on security/release-images.json, but the field was never added — and v0.75.0 is the first release since #1628 merged, so this is the first time it fired.

Worse, the gate that runs on every pull request (check-release-image-inventory.ts) validated only the images and upstream arrays and never looked at schemaVersion — so no PR could have caught the mismatch. Two validators disagreed about the same document, and only the release-time one was strict.

This adds the field, asserts it in the PR-time gate too, and pins the shipped file with a test.

How to test

  • node scripts/check-release-image-inventory.ts passes.
  • node --test scripts/check-release-image-inventory.test.ts scripts/verify-release-evidence.test.ts — 19/19 green.
  • Re-running the release gets tag-images past inventory validation.

No changeset: release evidence tooling only.

Summary by CodeRabbit

  • Bug Fixes

    • Improved release validation by requiring the release image inventory to declare schema version 1.
    • Added checks to catch invalid or missing inventory schema information earlier in the release process.
  • Chores

    • Updated the release image inventory format to include its schema version without changing the listed images.

…equires

verify-release-evidence.ts (added in #1628) rejects a release image inventory
without schemaVersion 1, but security/release-images.json never gained the
field, so tag-images died with "release image inventory is malformed" on the
first release since — after the tag was already cut.

The always-running check-release-image-inventory gate validated only the images
and upstream arrays, so no pull request could catch the mismatch. Assert the
schema version there too, with a test pinning the shipped file, so the two
validators can no longer disagree about the same document.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@github-actions github-actions Bot added bug Something isn't working size:S labels Aug 31, 2026
@coderabbitai

coderabbitai Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Team

Run ID: d40d286f-6eab-4f1f-9dfc-2e4e16dac7cb

📥 Commits

Reviewing files that changed from the base of the PR and between dbf0d4e and 87c3268.

📒 Files selected for processing (3)
  • scripts/check-release-image-inventory.test.ts
  • scripts/check-release-image-inventory.ts
  • security/release-images.json

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The release image manifest now declares schema version 1. Pull-request validation rejects inventories without that version, and a test verifies the shipped manifest.

Changes

Release inventory schema

Layer / File(s) Summary
Manifest schema validation
security/release-images.json, scripts/check-release-image-inventory.ts, scripts/check-release-image-inventory.test.ts
The manifest declares schemaVersion: 1. The checker rejects missing or invalid values. The test verifies the shipped manifest.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Merge Risk: ⚪ Minimal · up to 87c32

This localized change aligns release-inventory validation with the required schema and adds coverage for the shipped file; no actionable merge-blocking risk remains after normal checks and review.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the primary change: adding the inventory schema version required by the release gate.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2 files. (1 skipped: 1 unsupported.)

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/release-inventory-schema-version

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@FelixTJDietrich
FelixTJDietrich added this pull request to the merge queue Aug 31, 2026
Merged via the queue into main with commit 1c3d776 Aug 31, 2026
32 checks passed
@FelixTJDietrich
FelixTJDietrich deleted the fix/release-inventory-schema-version branch August 31, 2026 23:54
@github-actions

Copy link
Copy Markdown
Contributor

📚 Documentation Preview

Preview has been removed (PR closed)

@github-actions

Copy link
Copy Markdown
Contributor

🧩 Storybook Preview

Preview has been removed (PR closed)

FelixTJDietrich added a commit that referenced this pull request Sep 1, 2026
…pipeline

Reverts 8984f73 (chore(release): version packages).

The v0.75.0 release cut its draft, then tag-images failed: it checks out the
release commit, and 8984f73 predates both pipeline fixes it needs — the
SIGPIPE in release-notes extraction (#1684) and the missing inventory
schemaVersion (#1685). A release anchored there can never pass, and the draft
carried no tag and no assets, so it was deleted.

Restoring the pending changesets lets the changesets bot regenerate the version
PR on top of the fixes, so v0.75.0 ships from a commit whose pipeline works —
same version, same notes, no gap in the released series.
@github-project-automation github-project-automation Bot moved this to Backlog in Hephaestus Sep 1, 2026
@github-project-automation github-project-automation Bot moved this from Backlog to Done in Hephaestus Sep 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant