Skip to content

fix(release): unify Open VSX trusted-publisher workflow_ref across channels - W-24666922 - #8537

Open
madhur310 wants to merge 4 commits into
developfrom
ms/W-24666922-unify-openvsx-workflow-ref
Open

madhur310 wants to merge 4 commits into
developfrom
ms/W-24666922-unify-openvsx-workflow-ref

Conversation

@madhur310

@madhur310 madhur310 commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Adds publishOpenVSXTrusted.yml — the one top-level workflow both stable and prerelease now use to actually run ovsx publish.
  • publishOpenVSX.yml loses its own publish job (moved to the new file); verify-published can no longer needs: it (cross-workflow-run dependencies aren't possible), relying instead on its existing poll-loop tolerance.
  • promote-to-prerelease.yml gains a trigger-openvsx-publish job that dispatches publishOpenVSXTrusted.yml via gh workflow run for the nightly being promoted.

Context

Open VSX's trusted-publisher check matches the OIDC token's workflow_ref claim — the top-level workflow that initiated the run — not job_workflow_ref (confirmed against eclipse-openvsx/openvsx's GitHubTrustedPublishingProviderSupport.matches() and TrustedPublishingService.registerTrustedPublisher(), which hard-rejects a second trusted-publisher registration per extension, server-side). Stable (publishOpenVSX.yml, fires on release: types: [released]) and prerelease (promote-to-prerelease.yml, fires on schedule) were two different top-level files, so no single trusted-publisher registration could ever cover both.

publishOpenVSXTrusted.yml is deliberately not nested via uses: under either existing file: stable triggers it directly via its own release event (a sibling of publishOpenVSX.yml, not nested inside it — multiple workflow files independently reacting to the same event is normal), and promote-to-prerelease.yml dispatches it via gh workflow run (a genuinely new, independently initiated run, not a uses: call) — so both runs' workflow_ref is publishOpenVSXTrusted.yml either way.

It deliberately has no environment: publish (unlike publishOpenVSX.yml's prepare-release-metadata): that environment has a required_reviewers protection rule, which would otherwise turn every automated weekly prerelease into one requiring manual approval.

vscode-promote-prerelease.yml's own inline ovsx leg is being removed in a parallel github-workflows PR (salesforcecli/github-workflows#199), since Open VSX publishing for prerelease now happens via this dispatch instead.

Two uses: refs in this PR are temporarily pinned to the github-workflows PR branch (salesforcecli/github-workflows@ms/W-24666922-ovsx-trusted-publishing) instead of @main, to validate end-to-end before that PR merges — marked TEMPORARY in both files. Must switch back to @main before this PR merges, coordinated with that PR's merge.

Validation

  • actionlint on all three files: zero new findings vs. develop (same pre-existing shellcheck notices only).
  • Real end-to-end dispatch confirmed: ran publishOpenVSXTrusted.yml directly (pinned to the github-workflows test branch) against an already-published, --skip-duplicate-safe nightly tag, covering all 17 Open VSX-published extensions in this repo — no new content reached the registry. Run 41499926285 / publish job: 🔐 Trusted publishing token issued for ... logged for every extension, zero ❌ No trusted publisher matches errors.
  • Trusted publisher registered on open-vsx.org for each extension against publishOpenVSXTrusted.yml (via the registration-only #8555, merged, to get the workflow name onto develop first).

Test plan

  • Dry-run promote-to-prerelease.yml and confirm trigger-openvsx-publish is skipped under dry-run: true
  • Manually dispatch publishOpenVSXTrusted.yml against an existing nightly tag; confirmed real (non-dry-run) run against an already-published, --skip-duplicate-safe tag succeeds with no new content published — see Validation above
  • Switch both temporary uses: refs back to @main once fix(release): migrate Open VSX publishing to OIDC trusted publishing - W-24666922 salesforcecli/github-workflows#199 merges
  • Register the Open VSX trusted publisher for each extension against publishOpenVSXTrusted.yml

@W-24666922@

Manual test plan

Nothing worth manually testing.

…24666922

PR #200 (vscode-promote-prerelease.yml's ovsx removal) got folded into #199
and closed, so the temporary test pin here needs to point at #199's branch
too, matching publishOpenVSXTrusted.yml's pin.
@madhur310
madhur310 requested a review from a team as a code owner October 28, 2026 23:14
@madhur310
madhur310 requested a review from gbockus-sf October 28, 2026 23:14
# Conflicts:
#	.github/workflows/promote-to-prerelease.yml
madhur310 added a commit that referenced this pull request Nov 2, 2026
… - W-24666922 (#8555)

Split out of the full W-24666922 migration PR (#8537) as its own minimal,
standalone addition. A workflow_dispatch workflow can't be run by filename
until it exists on the repo's default branch, even when you intend to run
a different branch's content via --ref -- so this exists purely to
register the file on develop for dispatch testing.

Deliberately omits #8537's automatic release: types: [released] trigger:
with Open VSX trusted publishing not yet fully rolled out, this shouldn't
fire on the next real stable release before that lands. #8537 supersedes
this with the full version once it merges.

This branch has not been deployed

No deployments
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