Skip to content

chore: make the setup-node contract assertion version-agnostic - #154

Merged
antonio-orionus merged 2 commits into
mainfrom
chore/tooling-contract-setup-node-version
Aug 8, 2026
Merged

chore: make the setup-node contract assertion version-agnostic#154
antonio-orionus merged 2 commits into
mainfrom
chore/tooling-contract-setup-node-version

Conversation

@antonio-orionus

Copy link
Copy Markdown
Owner

Unblocks #138 (actions/setup-node v6 → v7).

check-tooling-contract.mjs asserted the literal string uses: actions/setup-node@v6, so any setup-node major bump fails the gate regardless of whether anything is actually wrong. That is what #138 tripped over.

The contract's intent is that Node is set up for registry trusted publishing — not which release of the action does it. node-version: 24, the registry URL, the OIDC permission and the publish command all stay asserted, because those are the parts that carry meaning.

Verified the relaxed assertion still fails when setup-node is removed from the workflow entirely, so it has not become vacuous.

bun run check green.

The tooling contract hardcoded `uses: actions/setup-node@v6`, so every
setup-node major bump failed the gate — which is exactly what blocked #138
(v6 -> v7). The contract's intent is that Node is set up for registry trusted
publishing, not which release of the action does it; node-version: 24 and the
registry URL stay asserted because those are the parts that actually matter.

Verified the relaxed assertion still fails when setup-node is absent entirely.
@coderabbitai

coderabbitai Bot commented Aug 8, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 0f570f3f-689b-489a-a309-589a142ab14c

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

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.

The regex form had no regex features, so oxlint's prefer-includes flagged it.
Prefix matching on 'uses: actions/setup-node@' is simpler and equally
version-agnostic; re-verified it still fails when setup-node is absent.
@antonio-orionus
antonio-orionus merged commit 5d876b0 into main Aug 8, 2026
15 checks passed
@antonio-orionus
antonio-orionus deleted the chore/tooling-contract-setup-node-version branch August 8, 2026 10:04
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.

1 participant