Skip to content

Split registration out of /-/publish into a dedicated /-/register#53

Merged
fengmk2 merged 1 commit into
mainfrom
refactor/dedicated-register-endpoint
Jul 2, 2026
Merged

Split registration out of /-/publish into a dedicated /-/register#53
fengmk2 merged 1 commit into
mainfrom
refactor/dedicated-register-endpoint

Conversation

@fengmk2

@fengmk2 fengmk2 commented Jul 2, 2026

Copy link
Copy Markdown
Member

Summary

Follow-up to #52: the register boolean made /-/publish do two jobs. Now:

  • POST /-/publish {ref, packages}: stores metas only, never registers. An empty packages is always a 400.
  • POST /-/register {ref, prUrl?} (new): registers the ref, making its published versions visible; stamps publishedAt at the moment the release actually becomes installable.

The action's final call moves to /-/register; its per-package publish calls just drop the flag. Docs updated.

BREAKING: coordinate the deploy with a pin bump

/-/publish no longer registers, so any action pinned to an older commit (vite-plus currently pins f867796) will store artifacts but never make a NEW sha visible after this deploys. Merge order:

  1. Merge + deploy this PR
  2. Immediately bump the vite-plus pin in publish-to-pkg.pr.new.yml to this merge commit

(Re-publishes of already-registered shas keep working in the gap; only brand-new shas are affected.)

Test plan

  • Failing-first tests for the new endpoint (auth, validation, visibility flip, prUrl/publishedAt recording)
  • All publish call sites in the suite converted to the two-call protocol; 83/83 passing
  • pnpm typecheck, action bundle rebuilt

The register boolean added in #52 made one endpoint do two jobs. Publishing
now only stores metas (empty packages is always a 400), and the new
/-/register endpoint registers the ref, stamping publishedAt at the moment
the release becomes visible. The action's final call moves to /-/register.

BREAKING for older action pins: /-/publish no longer registers, so an action
pinned before this commit will store artifacts but never make a NEW sha
visible. Bump the vite-plus pin to this commit together with deploying it.
@fengmk2 fengmk2 merged commit 4072b81 into main Jul 2, 2026
4 checks passed
@fengmk2 fengmk2 deleted the refactor/dedicated-register-endpoint branch July 2, 2026 01:58
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