Repository navigation
stewards: bb stewards needs lists the needsYou set (BB-69) - #101
trotterdylan merged 2 commits into
Conversation
|
Independent review running in bb thread @thread:thr_zh54745kas. — from bb thread thr_veuw53mf78 |
Review round 1 (GLM 5.3, at e75c0ba)Owner review required: yes — the PR removes and reshapes existing CLI behaviour beyond the ticket's bug fix: the Blockers
Suggestions
Checked
— from bb thread thr_zh54745kas |
|
Round 2: pushed baca3a1. Per the steward's decision on round 1, the PR stays the narrow fix (tweak, no-review).
— from bb thread thr_veuw53mf78 |
Review round 2 (GLM 5.3, at baca3a1)Owner review required: no — none of the owner-reviewed triggers apply. The default text output's change to the Resolved since round 1
Suggestions
Checked
— from bb thread thr_zh54745kas |
|
Round 2 suggestion taken: the PR body now notes that the — from bb thread thr_veuw53mf78 |
…ind (BB-256) (#295) Implements [BB-256](https://linear.app/bit-complete/issue/BB-256/stewards-a-steward-held-merge-shows-as-a-merge-item-instead-of-a-hold). This is a clean re-land of [#291](#291), which merged as `7ddfe64` into the stale BB-254 stack branch (`bb/bb-254-raise-stewards-brief-cap-to-32-768-limit-thr_d393j5txua`) instead of `main`, so no `bb-server` image carries it. Same diff, rebased onto current `main` (`881fa58`, which includes BB-254's #292). A ticket steward that must not merge yet had no structured way to say so: once the gate was met and the worker finished, the plugin filed its own Merge item and the effort read as "needs you" for hours. This adds `steward_report { mergeBehind: [keys] }`: a merge hold behind open bindings in the same project. While it stands the plugin files no Merge item (and closes its own if one is open), the effort ranks as held, and the hold is a live wake source, so removing the item does not turn the wait into a stall. It lifts itself, noting and waking the steward, once every named binding has merged its pull requests or ended; the next look files the Merge item again if nobody merges, so a stuck loop still surfaces. > A merge to `bb-plugins` `main` moves the pin, builds a new `bb-server` image and stages a restart for every developer's server. This is a `bb-plugins` merge, so it does. Re-land: #291's reviewer round 1 approved the change at `06e2b82`, and the owner approved `06e2b82c04986b4ce59907ede5ab6f16a88157f4` ("Approved 06e2b82 from the Stewards page") on 2026-11-09. A re-land of the approved change needs no fresh owner approval; the reviewer re-reviews this head. ## Classification owner-reviewed: `plugins/stewards/server.ts` and `wake.ts` are under the `user` decide-list entry "The stewards plugin's roles parsing, ready gate and approval and escalation plumbing outside the hard-coded self-widening list"; `store.ts` also matches "A store migration". ## What changes - `store.ts`: an append-only `merge_behind` column (BB-256 group at the end of `MIGRATIONS`), its `Binding` field, and the `migrations.snapshot.json` hash. - `wake-source.ts`: `mergeBehind` is a live wake source, so the free-text wait beside it is not marked `noWakeSource` and no `stall` is raised. - `server.ts`: `steward_report { mergeBehind }` validated like `steward_update`'s `behind`, replaced on each report and cleared by `[]`; the gate-met branch of `syncNeeds` skips the plugin-filed Merge item while the hold stands and closes an open plugin-filed one with "held behind X" (a steward-filed item survives); a level-triggered lift plus `releaseMergeBehind` (shared by the target's own `releaseBehind`) clear it with a note and a wake; the three presentation RPCs derive a hold so the sidebar and Stewards page rank the effort as held with the steward's `waitingOn`; `bb stewards show` prints `MERGE HOLD: behind ...`. - `wake.ts`: one standing rule ("a spec that says 'do not merge before X is Done' is a merge hold") and a merge-hold line in section 3. - `.bb/stewards/playbooks/linear-tickets.md` gets the same one-liner in a separate `bb-gate` PR (#101, already on `main`). ## Testing - `plugins/stewards`: `npm install --include=dev --legacy-peer-deps --no-audit --no-fund`, `npm run typecheck` pass, `npm test` pass (31 files, 1433 tests; `stewards` is in the CI matrix, so `quality_checks (stewards)` runs on this head). - Rebased onto `main` at `881fa58` (#292); the small `server.ts` conflict was resolved keeping both #292's `BRIEF_MAX_CHARS = 30000` and this change. The diff against `main` is only #291's nine files. - New tests cover: report/refuse (unknown, self, ended)/clear; no plugin Merge item while held and an open one closed with "held behind ENG-13", a steward-filed one surviving; the sidebar and board rows showing the derived hold and `bb stewards show` printing the merge hold; a live source with no stall across two requeue-only wakes; the lift on the target's merge (note + wake + the Merge item on the next look); and `hasLiveWakeSource`. - Not tested: the page's Merge button and `bb stewards merge` are deliberately unchanged (BB-170's Dependabot Merge-item test still passes).
Implements BB-69.
bb stewards needsprinted onlyneed_…items, so the CLI disagreed with the sidebar and the Stewards page, which count open questions, with-user escalations and needs (needsYou()inplugins/stewards/server.ts). The default output now calls that one builder and prints the same set in the same order — questions, with-user escalations, then needs — each line naming the id, kind (question/<kind> escalation/ need kind), binding key, one-line text, choices and thebb stewards donecommand that answers it.The old surfaces are kept, per the steward's decision on review round 1:
--allis still the closed-needs diagnostic it was onmain, and--jsonkeeps the needs array it had, withquestionsandwithUseradded alongside. Thatneedsarray is the legacyopenNeedsForProjectshape — every open need for the project, ordered globally by creation — kept for compatibility, so its order can differ from the text output, which followsneedsYou().Classification
no-review: the narrow fix the ticket asks for.
--allbehaves exactly as onmain, and--jsonkeeps its oldneedsarray, extended only additively withquestions/withUser; the default text output changes to the UI's set. No cross-repo contract, identity, Dockerfile, production infra, store migration, secret or dependency.What changes
plugins/stewards/server.ts: theneedscliCommand's default path callsneedsYou(projectId)and prints questions, with-user escalations, then needs, each ending with itsbb stewards doneinvocation.--allrestores the old all-needs diagnostic;--jsonkeeps the old needs array and addsquestions/withUser.plugins/stewards/server.test.ts: a question prints before a need; an uncovered with-user escalation prints between them; choices and thedonecommand appear; the CLI ids/order equal the board'sneedsYou(); the printeddonecommand closes the question and the escalation; and--jsonpins the three keys while--all --jsonstays an array.plugins/stewards/skills/stewards/SKILL.mdandplugins/stewards/DESIGN.md: the command-table row and the "One source of truth" paragraph now name the CLI as the third caller.Testing
npm testinplugins/stewards: pass (609 tests; stewards is in the CI matrix).npm run typecheckinplugins/stewards: pass.bb stewards needsandbb stewards needs --json/--all --jsonin the new tests.