bc-khoe.27.10: B7e-shipcheck — What this branch actually ships - #644
Open
mordam wants to merge 7 commits into
Open
bc-khoe.27.10: B7e-shipcheck — What this branch actually ships#644mordam wants to merge 7 commits into
mordam wants to merge 7 commits into
Conversation
…hether the delivery will be refused Adds lib/shipcheck.js + bin/b7e-shipcheck: resolves the base as a merge-base against a freshly fetched origin/<base> rather than a bare main...HEAD, then reports the committed diff and reproduces bin/deliver.js's own three guard clauses (detached HEAD, branch-equals-base, a dirty tree) verbatim, so the verdict cannot drift from the real refusal. Wires the four usual registrations: package.json + package-lock.json bin entries, Bash(b7e-shipcheck:*) on DEFAULT_TOOL_LIST (lib/toolbelt.js) plus the matching lib/grants.js read classification, a README section, and test/b7eshipcheck.mjs (pure deliverVerdict checks plus real throwaway-git-repo checks). Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Owner
Author
|
A beadcause worker opened this and does not merge its own work. It is on the merge queue as bc-xkv7r. |
Owner
Author
|
The beadcause merge queue tried to merge this and could not: it has been tried 3 times and stopped at the same place each time. the branch still conflicts with |
…k-khoe2710 # Conflicts: # README.md # package-lock.json # package.json
Contributor
|
beadcause-resolver: stood down — worktree-b7e-shipcheck-khoe2710 is locked by another live resolver window ( |
…k-khoe2710 # Conflicts: # README.md
…k-khoe2710 # Conflicts: # package-lock.json # package.json
…c-wbrhi Resolving the merge of origin/main into this branch. main moved the `b7e-*` half of the read-only surface out of `lib/grants.js` and `lib/toolbelt.js` and into the tools' own headers: a `bin/b7e-*` file says `@grant read`, `write` or `excluded`, and `lib/tooldecl.js` assembles both registries from that. This branch predates it and still appended a line to each, which is where both conflicts were. Both registries are taken from origin/main verbatim and the classification they carried moves into `bin/b7e-shipcheck`'s header. `read` rather than `write` for the reason this branch already gave: every path through it is a `git fetch`/`diff`/`status`/`merge-base` read, and it never pushes, commits or talks to `gh`. `node bin/b7e-enroll b7e-shipcheck` says nothing is owed, and this branch now touches neither registry. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
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.
Adds
b7e-shipcheck(bc-khoe.27.10): one call that answers "what does this branchactually ship, and would
bin/deliver.jsrefuse it right now" — the question five priorsessions (bc-khoe.27.5, bc-fh0sz, bc-xl7n.109, bc-gdub, bc-khoe.27.7) each answered by
hand, with a different git incantation each time, twice only finding out about a real
refusal after the delivery summary was already written.
lib/shipcheck.jsresolves the base as a merge-base against a freshly fetchedorigin/<base>(never a baremain...HEAD, which is exactly what read empty forbc-gdub.1 against a stale local
main), then reports the committed diff against thatbase and reproduces
bin/deliver.js's own three guard clauses verbatim — detached HEAD,branch-equals-base, a dirty working tree — so the sentence this prints is the sentence
the real refusal would print, before a session has written a word of delivery prose.
bin/b7e-shipcheckis the thin CLI (--base, --dir, --json, -b for a cosmetic beadlabel), the same split
lib/blame.js/bin/b7e-blamealready use.Chose NOT to replicate
lib/conflicted.js'sinspectBranch(committed merge-conflictmarkers, an unparseable commit) — that's a check on the committed blobs deliver.js runs
after these two, and a different question from "what does this branch ship and is the
tree clean enough to ship it"; the bead's own Returns section didn't ask for it either.
Also did not add a literal "here's the deliver.js invocation to run" printout — the
acceptance criteria's "prints an invocation that succeeds once it is gone" reads as the
same b7e-shipcheck call itself going from a refusal to a clean verdict, not a new
feature to generate a shell command, and the Command's own Returns spec doesn't mention
one.
Wired the usual four registrations: package.json + package-lock.json bin entries,
Bash(b7e-shipcheck:*) on DEFAULT_TOOL_LIST in lib/toolbelt.js (plus the matching
lib/grants.js
{kind:'read'}classification test/grants.mjs enforces), a README section,and test/b7eshipcheck.mjs — pure checks against deliverVerdict() plus real throwaway-git-repo
checks (bare origin + working clone/clone, same shape test/blame.mjs uses) proving: the
dirty-tree case names the offending file and clears once it's gone; the branch-equals-base
case refuses instead of printing a main-into-main invocation; and a checkout with no local
mainref at all (onlyorigin/main) still resolves correctly where a baregit diff main...HEADthrows outright.Two sibling sessions are also editing lib/toolbelt.js right now (bc-68ou.14, bc-68ou.15) —
checked their diffs before editing; both land in different regions of the file (a
"NOT on this list" comment block, and a b7e-unlanded entry near b7e-brief), and mine is a
third, separate insertion right after b7e-owes, so a merge conflict there is unlikely but
worth flagging in case two of these land in the same sweep.
Tests: node bin/b7e-gate --log /tmp/shipcheck-gate.log — all 421 suites passed (full parallel gate, ~run of scripts/test.mjs's whole discovered set); also ran node test/b7eshipcheck.mjs (7 CLI checks + unit/fixture checks) directly, and node bin/b7e-shipcheck itself against this branch to confirm its own verdict reads clean.
Files changed — 8 files · +642 −0 · against `main`
Opened by a beadcause worker session on bc-khoe.27.10 — b7e-shipcheck — What this branch actually ships, and whether the delivery will be refused. It merges itself once the checks report; merging is what closes the bead. If this is still open, something stopped that, and the reason is on bc-khoe.27.10 and in Adam's inbox.
bead: bc-khoe.27.10