Skip to content

Gate the release/flip on the live e2e suite (today it's PR-only behind manual env approval)#337

Merged
clkao merged 1 commit into
nextfrom
spacedock-ensign/gate-release-on-e2e
Jun 9, 2026
Merged

Gate the release/flip on the live e2e suite (today it's PR-only behind manual env approval)#337
clkao merged 1 commit into
nextfrom
spacedock-ensign/gate-release-on-e2e

Conversation

@clkao

@clkao clkao commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator

The release/tag path ran no end-to-end check; now a v* cut cannot publish unless the live e2e suite passed green for that exact commit.

What changed

  • Add an e2e-gate job to release.yml that goreleaser now needs:.
  • Block the cut unless a green live-e2e run matches the tagged commit's SHA.
  • Add the pure EvaluateE2EGate predicate and spacedock-release e2e-gate subcommand.
  • Add an audited SPACEDOCK_E2E_GATE_WAIVER escape hatch for emergency cuts.
  • Re-align journey_workflow_test.go anchors to the new header; keep ledger separation.

Evidence

  • go test ./internal/release/ ./cmd/spacedock-release/ → 80/80 passed; the whole internal/release package is green.
  • Detached adversarial audit: 7 weakenings each caught RED by the deliverable's own tests; no material findings.

Review guidance

  • Focus on journey_workflow_test.go: the needs: e2e-gate edge re-aligns four byte-literal anchors; goreleaser must need exactly [e2e-gate], never the ledger.

nzb

Add an `e2e-gate` job to release.yml that goreleaser `needs:`. It resolves
the tagged commit SHA (`git rev-list -1 "$GITHUB_REF_NAME"`) and asks the new
`spacedock-release e2e-gate` subcommand whether a `conclusion: success`
Runtime Live E2E run exists for that exact commit — a green run means every
live lane was approved and passed (a parked/offline-only run is never
`success`). No matching run blocks the cut. `SPACEDOCK_E2E_GATE_WAIVER` (a
non-empty reason) is the auditable captain-waiver escape hatch, recorded to
$GITHUB_STEP_SUMMARY.

The SHA-match decision is a pure `EvaluateE2EGate` predicate in
internal/release, mirroring the journey-costs subcommand shape. AC-1 is
proved by a workflow-guard test parsing the real release.yml (needs-edge +
SHA-bound gate step) with adversarial dropped-edge / weakened-SHA variants
the guard rejects; AC-2/AC-3 by predicate + subcommand unit tests over
fixture run-list JSON for the pass/block(parked,wrong-SHA,empty)/waiver
cases. No live run at implementation time.

M2 co-edit (same change): the `needs: e2e-gate` edge changes the goreleaser
job header, so the four byte-literal `goreleaser:`/`runs-on: macos-latest`
anchors in journey_workflow_test.go track the new header and the no-`needs`
assertion now requires goreleaser needs exactly ["e2e-gate"] (never
journey-ledger). `go test ./internal/release/` is green over the whole
package (AC-4).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
clkao added a commit that referenced this pull request Jun 9, 2026
@clkao clkao merged commit cd4fd45 into next Jun 9, 2026
4 of 7 checks passed
clkao added a commit that referenced this pull request Jun 9, 2026
clkao added a commit that referenced this pull request Jun 9, 2026
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