Skip to content

ci(publish): don't strand the GitHub release on transient registry failure#35

Merged
dmartinochoa merged 1 commit into
mainfrom
chore/publish-resilient-release-step
May 21, 2026
Merged

ci(publish): don't strand the GitHub release on transient registry failure#35
dmartinochoa merged 1 commit into
mainfrom
chore/publish-resilient-release-step

Conversation

@dmartinochoa
Copy link
Copy Markdown
Member

Summary

  • Publish to VS Code Marketplace and Publish to Open VSX now run with continue-on-error: true.
  • Create GitHub release runs as long as at least one registry accepted the publish (so the .vsix + SBOM still land somewhere a user can grab them).
  • New trailing Registry publish status step re-asserts the job-level failure when either publish errored — so partial-success runs are still red in the run UI, in branch protection, and in any notification wiring.

Why

v1.0.2's publish run (26152644715) failed at Publish to Open VSX with an HTTP 405 — a transient Open VSX server-side hiccup (v1.0.1 shipped unchanged 14 h earlier through the same code path). Because the publish step is a run: script under bash -e, the job aborted at that line and Create GitHub release never ran. Net state for v1.0.2 was: ✓ VS Code Marketplace, ✗ Open VSX, ✗ GitHub Release. Recovery cost a fresh 1.0.x tag (v1.0.3 via PR #34).

After this change, that same incident would have left v1.0.2 on Marketplace and on GitHub Releases, with only the Open VSX gap to chase — no need to burn a new tag to recover the GH release.

Behaviour matrix

Marketplace Open VSX GH release Job
created green
created red
created red
skipped red

Rows 2 and 3 are the changed behaviour. Rows 1 and 4 are unchanged.

Why conclusion not outcome in the status gate

The status step uses steps.<publish>.conclusion == 'success' to decide whether to run, but steps.<publish>.outcome to decide whether to fail. That's deliberate:

  • outcome is the raw step result (the actual exit-code success/failure).
  • conclusion is the post-continue-on-error roll-up (always 'success' for any continue-on-error step that ran, 'skipped' for steps that didn't reach execution).

So:

  • conclusion == 'success' filters out runs where lint/tests/audit failed upstream of publish — the status step stays quiet on those.
  • outcome != 'success' correctly catches a real registry failure even though continue-on-error masked it from the job-level result.

Test plan

  • YAML parses (python -c \"import yaml; yaml.safe_load(open('.github/workflows/publish.yml'))\").
  • Reviewed expression semantics against GitHub Actions docs on steps.<id>.outcome vs .conclusion.
  • Real-world validation comes on the next release — a successful publish (both registries green) exercises rows 1 of the matrix. The partial-failure rows can only be exercised by a registry returning an error, which is by definition out-of-band — no good way to test in advance short of pointing OVSX_PAT at a deliberately-bad endpoint.

Out of scope

  • Backfilling the GitHub release for v1.0.2 (still cosmetically missing). v1.0.3 supersedes v1.0.2 on every channel; cheap to add later if you want strict per-tag parity.
  • Automated re-publish-only mode for the failed-registry retry case. The current workflow does support workflow_dispatch with tag: input, and with this PR a manual re-dispatch on the same tag is safer (a duplicate Marketplace publish would now continue-on-error rather than abort the job).

🤖 Generated with Claude Code

…failure

Both registry publishes now use `continue-on-error: true` and the
"Create GitHub release" step runs as long as at least one registry
accepted the publish. A new "Registry publish status" step at the
end re-asserts the job-level failure when either publish errored,
so partial-success runs are still visible in the run UI / branch
protection / notifications.

Motivation: v1.0.2's publish workflow failed at "Publish to Open VSX"
with an HTTP 405 (transient registry-side; v1.0.1 shipped unchanged
14 h earlier). Because the publish step is a `run:` script with
`bash -e`, the job aborted there and "Create GitHub release" never
ran — so v1.0.2 made it to the VS Code Marketplace but was missing
from both Open VSX and GitHub Releases. The recovery cost a fresh
1.0.x tag (v1.0.3).

Behaviour matrix after this change:

  vsce | ovsx | GH release | job
  -----|------|------------|-----
  ✓    | ✓    | created    | green   (unchanged)
  ✓    | ✗    | created    | red     (was: not created, red)
  ✗    | ✓    | created    | red     (was: not created, red)
  ✗    | ✗    | skipped    | red     (unchanged)

The status step gates itself on `steps.<publish>.conclusion == 'success'`
so it stays quiet when the job fails upstream of publish (lint, tests,
audit, etc.) — `conclusion` is the post-`continue-on-error` roll-up,
which is 'success' for any publish step that actually executed and
'skipped' for steps that never reached execution.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 21, 2026

Warning

Rate limit exceeded

@dmartinochoa has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 35 minutes and 59 seconds before requesting another review.

You’ve run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9dfab23b-bcc4-4e8e-813a-f4a8a5323f28

📥 Commits

Reviewing files that changed from the base of the PR and between 21a5e26 and 2c56b67.

📒 Files selected for processing (1)
  • .github/workflows/publish.yml
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/publish-resilient-release-step

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 and usage tips.

@dmartinochoa dmartinochoa merged commit b7cdab4 into main May 21, 2026
12 checks passed
@dmartinochoa dmartinochoa deleted the chore/publish-resilient-release-step branch May 21, 2026 11:33
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