Skip to content

fix(release): stage every package so pnpm's trust policy accepts new releases - #435

Merged
vite-hub[bot] merged 1 commit into
mainfrom
fix/publish-trust-evidence
Nov 16, 2026
Merged

vite-hub[bot] merged 1 commit into
mainfrom
fix/publish-trust-evidence

Conversation

@onmax

@onmax onmax commented Nov 16, 2026 •

Copy link
Copy Markdown
Owner

With pnpm's trustPolicy: no-downgrade, no current comark-ui installs. On pnpm 12.18.0:

[ERR_PNPM_TRUST_DOWNGRADE] High-risk trust downgrade for "[email protected]" (possible package takeover)
This error happened while installing the dependencies of [email protected]
Earlier versions had staged publish, but this version has trusted publisher.

pnpm ranks evidence as staged publish (_npmUser.approver) > trusted publisher with provenance > provenance alone (trust_checks.rs). It refuses a version when any version published before it has stronger evidence. comark-annotate, comark-carousel and comark-zoom shipped 0.1.0 to 0.2.0 staged. #42 switched to npm publish to skip the per-package 2FA approvals, so everything from 0.4.1 on went out one rank lower. Those three packages are blocked from 0.4.1 to 0.12.2, and comark-ui and comark-linter fail through them. The other 51 packages were never staged, so they install fine.

This PR moves the release back to npm stage publish, so every package carries the strongest evidence pnpm knows. The publish job lists the dependency waves in its summary, so approvals go in the same order as before. A new verify job waits for the approvals and fails for any version that went out without a staged publish, naming the downgrade when there is one. test/npm-trust.test.ts fails if the workflow calls npm publish again, so this is checked in CI without secrets.

The 0.4.1 to 0.12.2 releases stay blocked, since pnpm only looks at publish order. Ranges heal once a staged 0.12.3 is out: pnpm sets a downgraded candidate aside and picks the next match, so [email protected] resolves ^0.12.1 to 0.12.3. The docs section on trust errors now says that.

Before the next release, each package's trusted publisher on npmjs.com needs npm stage publish allowed (and npm publish can go off). I couldn't check the current settings, and I haven't run a staged release from this workflow yet.

…releases

comark-annotate, comark-carousel, and comark-zoom began with staged publishes, which pnpm ranks above a direct trusted publish. Every release since 0.4.1 published directly, so pnpm's trustPolicy: no-downgrade refuses them. Releases are staged again, and a verify job fails for any version that goes out without a staged publish.
@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-16T09:49:28.013647Z
We couldn’t complete this review. Comment @codex review to try again.
54a315c PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found. No P0 or P1 findings remain.

Reviewed changes — Reviewed the release workflow, registry trust verifier, regression tests, and publishing documentation across all five changed files.

  • Staged releases: Changes tarball publication to npm stage publish through OIDC and lists dependency waves for manual approval.
  • Trust verification: Adds a separate approval-waiting job that rejects missing or unstaged releases and explains historical trust downgrades.
  • Regression coverage and guidance: Tests evidence ranking and the staging requirement, and documents blocked historical releases and release recovery.
  • Validation: All three focused tests, targeted lint, and targeted typechecking passed; CLI checks covered staged, missing, and downgraded versions. The npm CLI contract was checked against upstream source, but live staging and private trusted-publisher settings were not exercised.

Pullfrog  | View workflow run | Using gpt-6.1-sol(xhigh) | 𝕏

@pkg-pr-new

pkg-pr-new Bot commented Nov 16, 2026

Copy link
Copy Markdown

Open in StackBlitz

comark-annotate

pnpm add https://pkg.pr.new/comark-annotate@435

comark-badge

pnpm add https://pkg.pr.new/comark-badge@435

comark-bundle

pnpm add https://pkg.pr.new/comark-bundle@435

comark-cards

pnpm add https://pkg.pr.new/comark-cards@435

comark-carousel

pnpm add https://pkg.pr.new/comark-carousel@435

comark-cast

pnpm add https://pkg.pr.new/comark-cast@435

comark-charts

pnpm add https://pkg.pr.new/comark-charts@435

comark-chat

pnpm add https://pkg.pr.new/comark-chat@435

comark-chips

pnpm add https://pkg.pr.new/comark-chips@435

comark-cjk

pnpm add https://pkg.pr.new/comark-cjk@435

comark-code

pnpm add https://pkg.pr.new/comark-code@435

comark-code-notes

pnpm add https://pkg.pr.new/comark-code-notes@435

comark-colors

pnpm add https://pkg.pr.new/comark-colors@435

comark-comments

pnpm add https://pkg.pr.new/comark-comments@435

comark-critic

pnpm add https://pkg.pr.new/comark-critic@435

comark-deflist

pnpm add https://pkg.pr.new/comark-deflist@435

comark-details

pnpm add https://pkg.pr.new/comark-details@435

comark-diagrams

pnpm add https://pkg.pr.new/comark-diagrams@435

comark-diff

pnpm add https://pkg.pr.new/comark-diff@435

comark-embed

pnpm add https://pkg.pr.new/comark-embed@435

comark-fields

pnpm add https://pkg.pr.new/comark-fields@435

comark-figure

pnpm add https://pkg.pr.new/comark-figure@435

comark-file-tree

pnpm add https://pkg.pr.new/comark-file-tree@435

comark-footnotes

pnpm add https://pkg.pr.new/comark-footnotes@435

comark-git-graph

pnpm add https://pkg.pr.new/comark-git-graph@435

comark-github

pnpm add https://pkg.pr.new/comark-github@435

comark-icon

pnpm add https://pkg.pr.new/comark-icon@435

comark-include

pnpm add https://pkg.pr.new/comark-include@435

comark-keys

pnpm add https://pkg.pr.new/comark-keys@435

comark-links

pnpm add https://pkg.pr.new/comark-links@435

comark-linter

pnpm add https://pkg.pr.new/comark-linter@435

comark-magic-move

pnpm add https://pkg.pr.new/comark-magic-move@435

comark-mark

pnpm add https://pkg.pr.new/comark-mark@435

markdown-it-to-comark

pnpm add https://pkg.pr.new/markdown-it-to-comark@435

marked-to-comark

pnpm add https://pkg.pr.new/marked-to-comark@435

comark-mathml

pnpm add https://pkg.pr.new/comark-mathml@435

comark-media

pnpm add https://pkg.pr.new/comark-media@435

comark-metrics

pnpm add https://pkg.pr.new/comark-metrics@435

migrate-to-comark

pnpm add https://pkg.pr.new/migrate-to-comark@435

comark-outline

pnpm add https://pkg.pr.new/comark-outline@435

comark-properties

pnpm add https://pkg.pr.new/comark-properties@435

comark-qr

pnpm add https://pkg.pr.new/comark-qr@435

comark-quiz

pnpm add https://pkg.pr.new/comark-quiz@435

comark-reading-time

pnpm add https://pkg.pr.new/comark-reading-time@435

remark-to-comark

pnpm add https://pkg.pr.new/remark-to-comark@435

comark-sources

pnpm add https://pkg.pr.new/comark-sources@435

comark-steps

pnpm add https://pkg.pr.new/comark-steps@435

comark-table

pnpm add https://pkg.pr.new/comark-table@435

comark-tabs

pnpm add https://pkg.pr.new/comark-tabs@435

comark-tests

pnpm add https://pkg.pr.new/comark-tests@435

comark-time

pnpm add https://pkg.pr.new/comark-time@435

comark-ui

pnpm add https://pkg.pr.new/comark-ui@435

comark-xref

pnpm add https://pkg.pr.new/comark-xref@435

comark-zoom

pnpm add https://pkg.pr.new/comark-zoom@435

commit: 54a315c

@vite-hub
vite-hub Bot merged commit db3dd63 into main Nov 16, 2026
6 checks passed
@vite-hub
vite-hub Bot deleted the fix/publish-trust-evidence branch November 16, 2026 09:59
@vite-hub

vite-hub Bot commented Nov 16, 2026

Copy link
Copy Markdown
Contributor
Session Status Started Duration
Pending Completed Not started —

Latest result

Pull request merged.

Final answers

Session

Pull request merged.

This was referenced Nov 16, 2026
vite-hub Bot pushed a commit that referenced this pull request Nov 24, 2026
…tead of staging on npm (#484)

Staging made every package wait for its own security-key approval on npmjs.com. The npm environment now requires a reviewer, so a release takes one approval in GitHub and then publishes with npm publish through OIDC trusted publishing, as before #435.
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