Repository navigation
v1.91.353.0 fix(ship): Step 12 keeps VERSION on --keep-current, adds bump never, and waits for the owner's answer before an unattended bump (GST-380) - #3666
Merged
Conversation
… early bump write (GST-380) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…and waits for the owner's answer before an unattended bump (GST-380) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…rsion writes; typed session rows; never drift and --answer rejection cases) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…decides the write; Version Gate and validate understand bump never) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…on Gate's ordinary rules Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…ever Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
|
😎 This pull request was merged. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Step 12 on a repo that never versions unit PRs:
--keep-currentnow keeps VERSION, and an unattended bump waits for the owner's answer instead of writing. (The capture uses a fixture repo at 1.300.0.0 because the secret scanner reads 1.0.0.0 as an IP address.)Before/after as text: Step 12 on a repo that never versions unit PRs: --keep-current now keeps VERSION, and an unattended bump waits for the owner's answer instead of writing
Why
On gstack-evals, which has no ship policy and so runs
bump: ask, every Step 12 flag stopped withBUMP_LEVEL needed, so there was no way to ship a PR that leaves VERSION alone (gstack-evals#85). On gstack-evals#89 an unattended run took the recommended level and wrote 0.0.2 before anyone was asked. Now--keep-currentand--version <current>keep VERSION, a repo can declare"bump": "never", and an unattended session can't write a bump until the owner's words come back through--answer.Blast radius
The change sits in
gstack-ship-release version, the ship policy reader,gstack-restamp --nextand the Version Gate (lib/version-gate-train.ts,scripts/compare-pr-version.ts). Every new branch is gated on either a keep flag orbump: never, and the answer gate only fires for a non-interactive session underbump: ask, so interactive runs andbump: patchrepos (gstack itself runs changelog fragments) take the old path; the remote pregate ran the whole free tier on the final tree with 0 failures (script ran).Approvals
Source: gstack-approvals record for gsta-191/ship-keep-current (display only; not an approval citation).
Summary
A repo whose unit PRs never change VERSION had no way through Step 12, and an unattended /ship could write a bump the owner never approved. This PR fixes both:
--keep-currentand--version <current>printVERSION: <v> kept, write nothing and read no queue. A keep flag combined with--bumpor a different--versionstops and names the conflict, and theBUMP_LEVEL neededstop now mentions--keep-current."bump": "never"policy key. Step 12 keeps VERSION and asks nothing, refuses--bump, and stops on a branch that already moved VERSION. It needsmin_gstack_version(floorBUMP_NEVER_KEY_VERSION), and validation rejects it beside stamp-at-merge, train or changelog_fragments.gstack-restamp --nextneeds an explicit--bump/--versionunder it, and the Version Gate passes a kept VERSION.bump: ask, a Step 12 call that would write stops withBUMP_ANSWER_REQUIREDuntil it's rerun with--answer "<owner's words>".ship/DRIVER.mdlists it as an approval.Test Coverage
All new code paths have test coverage (Step 7 audit: 100%).
Tests ran: tests 103
Tests ran: typecheck count unavailable
Pre-Landing Review
Pass 1 (six specialists plus red team) found 2 blocking defects: the answer gate missed
--versionwrites on an ALREADY_BUMPED branch, and a test asserted the wrong thing. Both are fixed. Pass 2 (specialists, adversarial, outside voice on openai/gpt-6.1-sol) found 1 blocking defect: the answer gate didn't name every flag that decides the write. It's fixed. A fix-check on the touched hunks found nothing blocking, and its Version Gate note was fixed in 83bd272.REVIEW_LOOP: passes=2 blocking_found=3 deferred=0 noted=3 fixed=14 scope=frozen fix_checks=1 dispatches=13
Gate edits: 17 listed, 8 read, 0 findings — 0 kept, 0 restored, 0 open
Outside review: completed (openai/gpt-6.1-sol); its two findings were fixed.
Review notes
GSTACK_SESSION_KIND=interactiveitself skips the answer gate, and writes made outsidegstack-ship-releasearen't covered. The gate stops honest unattended runs from writing early; it doesn't prove the owner's words are real.BUMP_NEVER_KEY_VERSIONis set to a placeholder floor, the next minor release (1.92). The merge stamp should move it to the real introducing release throughstamp_paths. Until then, the reader-version check asks for that floor.bump: neverdoesn't work with the coordinator queue: gate-ahead and stamp refuse withRESTAMP_VERSION_SOURCEunless they get an explicit version.gstack-decision-logrejects x.y.z.w versions as MEDIUM PII, so Step 12'sShip <v>rows, including the--answerwords, are never saved.Exploratory QA
CLI only. The before/after above came from running the base and branch
gstack-ship-releaseagainst a temporary fixture repo outside the checkout.Eval Results
ship/SKILL.md workflow judge: PASS (c:3 c:4 a:4), $0.06, at 27e781b. No ship/ prose changed after that commit, so the result still applies.
Plan Completion
Approved plan autoplan-20261031024826 gate_rev 1 (A1 + B1, plus the three Highs and the Mediums): every item shipped. The CEO phase was closed and deferred under the eng-only fix-lane plan.
Verification Results
Every plan obligation passed: keep-current and
--version <current>with no write, the refusal tests, the early-write tests across four session kinds, bump-never validation, restamp, and the Version Gate cases. None failed, were blocked or were left unrun.TODOS
No TODO items completed in this PR.
Documentation
Status: current. The docs already describe this branch's Step 12 changes, so I made no edits.
Scope: base 514daeb..83bd272 (6 commits, 23 files) plus the new file changelog.d/gsta-191-ship-keep-current.md. Nothing is staged or unstaged. I searched the docs and authored templates for bump policy, --keep-current and restamp --next mentions.
Documentation health:
Coverage debt: bump never and --keep-current/--answer have reference coverage (docs/ship-policy.md, gstack-ship-policy init --explain, gstack-ship-release help) and how-to coverage through the STOP messages. There is no explanation section on when a repo should choose bump never over bump patch, which is a common gap. A future /document-generate run could fill it.
Diagram drift: none; no diagrams reference the changed modules.
Test plan
bun test --timeout 120000 test/ship-release.test.ts test/version-gate-fragments.test.ts test/gstack-ship-policy.test.ts test/compare-pr-version.test.ts test/gstack-restamp-queue.test.ts test/ship-policy-compat.test.ts test/skill-md-size-guard.test.ts: 103 pass, 0 failbun run typecheck: clean🤖 Generated with Claude Code