Skip to content

stewards: one escalation chain, worker → steward → project steward → user (BB-30) - #55

Merged
trotterdylan merged 4 commits into
mainfrom
bb/bb-30-one-escalation-chain-stewards-plugin-bb-thr_us83nzrcjm
Oct 21, 2026
Merged

trotterdylan merged 4 commits into
mainfrom
bb/bb-30-one-escalation-chain-stewards-plugin-bb-thr_us83nzrcjm

Conversation

@trotterdylan

@trotterdylan trotterdylan commented Oct 21, 2026 •

Copy link
Copy Markdown
Collaborator

Implements BB-30.

Merging to bb-plugins main stages a restart on every developer's server.

Classification

owner-reviewed: it changes existing behaviour (the questions and steward-filed needs tables, the ask/forward/needs tools, the owner-reviewed lane and prGate), it includes a store migration, and it changes the code the decide list's no-self-widening rule names. The reviewer decides the lane.

What changes

  • One escalation chain, one record. escalations gains the envelope (project_id, origin, chain, resolution_kind, url, data, answered_by, forwarded_from, head_sha) and the human-boundary fields. questions and the steward-filed decide/configure/provide-secret needs migrate into it; the old tables are renamed questions_legacy and needs_legacy (never dropped), and the plugin-filed gate items (approve-spec, approve-pr, merge) stay in a rebuilt needs table.
  • The decide list fails closed. stewards/project.json bigDecisions entries are marked decide: project | user with paths; a bare string, an unknown mark, a pull request whose files cannot be read, one that matches no project entry path, or a change to the list, bigDecisions, prGate or the approval code is the user's (decisions.ts, no self-widening, matching both workspace- and repo-relative paths).
  • Project-steward approval. An owner-reviewed PR raises an approve-decline escalation to the project steward. It approves a project entry with steward_update { binding, approve, entry }, recording a store-only approval bound to the head sha (a new push voids it, and only the project steward's thread may record one); a user entry is forwarded to the page and satisfied only by the user's unsigned GitHub approval.
  • Answers go straight to the originator. A resolve at any layer records the answer verbatim as guidance on the originating binding with who decided, notes the bindings between quietly, and queues one delivery to the originating thread (a bb thread tell for a worker, a wake for a steward). The forward path records each hop. New CLI bb stewards escalate.
  • steward_report { needs } refuses decide, configure and provide-secret, pointing at escalate; ask and a user-bound forward require a resolution. A resolve prompts for a lesson. DESIGN.md §10/§12/§18, README and the stewards skill describe the one chain.

Testing

  • npm run typecheck in plugins/stewards: pass.
  • npm test in plugins/stewards: pass (340 tests; stewards is in the CI matrix, and CI runs both).
  • New: decisions.test.ts (decide list fails closed, self-widening for workspace- and repo-relative paths, unreadable files, entry-path matching), the migration fixture in store.test.ts (questions and each steward-filed need kind carried with answers, old tables renamed), originator-delivery tests in store.test.ts, prGate project/user/unknown-lane tests in reconcile.test.ts, and server tests for the project-steward approval, the secret/done forward rendering, the page Done button, bb stewards escalate, the required resolution, and a worker-raised escalation forwarded two hops and answered on the page.
  • The .bb decide list itself is reviewed in the companion .bb guidance branch guidance-thr_us83nzrcjm (commit 4cf0e0d); the .bb repo has no GitHub remote here.

Round 1 review fixes: the secret/done forward now renders as the page's provide-secret item; the page Done button closes configure/provide-secret escalations; the self-widening guard matches repo-relative GitHub filenames; unreadable files fail closed; ask/forward require a resolution; the forward path records hops and the two-hop test is in; resolve prompts for a lesson; the wake's lane gate reads the project-steward approval.

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Independent review running in bb thread @thread:thr_cewrhv4df3.

— from bb thread thr_us83nzrcjm

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Review round 1 (GLM 5.3, at 39f12c9)

Owner review required: yes — it changes and removes existing behaviour (the questions and steward-filed needs tables, the ask/forward/needs tools, the owner-reviewed lane and prGate), it includes a store migration, and it is exactly the code the decide list's no-self-widening rule names (store/server/decisions/reconcile). @trotterdylan, this one needs your approval.

I read the acceptance criteria and the six approval limits from the ticket; the .bb side I read on branch guidance-thr_us83nzrcjm (commit 4cf0e0d). I traced the real tool paths against the store and verified the two fail-closed claims empirically (scratch vitest runs against the checked-out head; nothing was pushed).

Blockers

  1. server.ts:4315 / store.ts:775 — a forward with resolution: "secret" (or "done") never reaches the page. The forward path puts the human-boundary fields on a new is_question: 1 row (store.ask), but openQuestions (store.ts:775) excludes secret/done questions, and openEscalationNeeds excludes is_question = 1 rows — so the question row renders nowhere, and the needs list renders the original escalation instead, whose resolutionKind is still null and whose data is {} (reroute only sets route/recommendation). needFromEscalation then maps it to a plain decide item: no secret form, no Provide button, no requester thread — provide-secret is broken end-to-end for fresh forwards. Verified: after the exact forward sequence the page sees QUESTIONS: [], NEEDS: [[…, "decide", "Provide API_TOKEN.", {}]]. The tests miss this because escalationNeed (server.test.ts:307) fabricates the row directly in the shape the old machinery expects — a shape the real forward path never produces. This fails the "the page renders every open escalation with route: me from resolution" criterion and the provide-secret path of limit 5. The forward should write the human-boundary fields onto the escalation itself (or render the question row as the need).

  2. server.ts:3462, 3472 — the page's Done button cannot close a configure or provide-secret escalation. Both call store.closeNeedByKey, which only updates the needs table; these rows live in escalations now, so the update changes 0 rows, the action still returns "Marked done", the steward is woken saying the user did it — and the item stays open forever. The decide paths were fixed for this (closeNeed(need.id) falls back to resolve); these two were not. This is the "each resolution type closed from the page" criterion, unmet and untested for done/secret.

  3. decisions.ts:15 — the no-self-widening guard never fires for a real pull request. SELF_WIDENING_PATHS are workspace-relative (bb-plugins/plugins/stewards/server.ts, …), but github.files returns repo-relative filenames (plugins/stewards/server.ts), and nothing prefixes them. Verified: isSelfWidening(["plugins/stewards/server.ts", "plugins/stewards/store.ts", "plugins/stewards/decisions.ts"]) is false. So a PR in bb-plugins that rewrites the decide-list, prGate or approval code is classified by the named entry alone — and "A store migration" is a project entry, so this very PR could be project-steward-approved. That is precisely what approval limit 2 forbids. The tests pass only because they feed workspace-prefixed paths (t.githubFiles.set("acme/web#7", ["bb-gate/docs/hooks.md"])). Strip the repo-directory prefix from the lists, or add it to the filenames, and add a test with a real repo-relative path.

  4. decisions.ts:63 / server.ts:4198 — a pull request whose files cannot be read does not fail closed. decideFor([], "A store migration", …) returns project (verified): unreadable files only skip the self-widening check and fall through to the entry match, so the project steward can approve a PR whose changed files the plugin never saw. This contradicts decisions.ts's own docstring ("pass them as empty, which can only ever yield user") and github.ts's ("when the read fails … treats it as the user's"), and breaks the fail-closed rule of limit 1. The server test even enshrines it: githubFiles is unset when the approval is recorded, so the test's approval goes through on []. An empty/unreadable file list must yield user.

  5. server.ts:4073, 4304 — ask and forward do not require resolution. Both default it (choice when choices are given, else text). The acceptance criteria say they require it (and choices with choice), and the design makes the human-boundary fields something the project steward consciously supplies. The choice/secret validations are right; the requirement is not implemented.

  6. store.ts:1214 / server.ts — the chain is never built, and the required two-hop test is missing. addHop is dead code: no caller in server.ts. Forwarding (store.reroute at server.ts:4296) records no hop, keeps no rewording, so on resolve the bindings between never get their quiet note (limit 6 works only for hand-built chains) and the ticket's explicit test — a worker-raised escalation forwarded two hops, answered on the page, worker told, steward and project steward noted, neither woken — does not exist. The only delivery test (server.test.ts "delivers an answer to the originating worker as a tell") creates the escalation directly at route: me and resolves it at store level. Wire addHop into the forward path and add that test.

  7. server.ts:4373 — a resolve does not prompt for a lesson. The response to steward_update { resolve } ends at "resolved esc_…"; nothing asks whether this is a general judgement, and a decision the user makes on the page does not surface as a lesson candidate in the project steward's next wake. Both are in the ticket (the wake-lists criterion and the design's "asks for a lesson" / "carries it as a lesson candidate").

  8. wake.ts:203 — the wake's Lane gate line ignores the project-steward approval. prGate(e) is called without { projectApproved }, unlike every server.ts call site. This PR's own updated DESIGN.md §18 still promises the merge button, the filed item and the wake's gate line "all read it … in the same words the button acts on": after a project-steward approval the wake still says the gate is not met, and while the escalation is open it says "owner approval needed" where the project steward's is meant. Plumb the recorded approval (per head sha) into the wake input.

Suggestions

  • server.ts:2714 — a new push leaves a stale head_sha on the approval escalation. reroute does not update it, so a project-steward approval recorded afterwards binds to the void sha, resolves the escalation with "Approved", delivers that to the originator, and the gate still is not met (a fresh escalation next pass). The in-code comment claims the request is "re-pointed at the head"; make it so.
  • server.ts:4198 — approve: true for the spec gate is refused while a PR-approval escalation is open (the branch intercepts approve: true even without entry), and resolving a PR-approval escalation with approving words records a spec approval (the check at server.ts:4250 does not exclude resolutionKind === "approve-decline"). Both are easy to trip when a binding has the two approval kinds open at once.
  • app.tsx:430 — the "Answer in the project steward's thread." fallback row remains, though the criterion asks for none left. It should be unreachable now, but with blocker 1 the secret/done forwards currently degrade to empty-data needs rather than this row anyway; once 1 is fixed, remove the row or assert it is dead.
  • decisions.ts / config.ts — the entries' paths are parsed but never used to verify the project steward's classification (only SELF_WIDENING_PATHS is consulted); either check the PR's files against the named entry's paths or drop the field.
  • store.ts resolve — every mechanical resolution ("The pull request is closed.", "Approved.") now writes itself as binding guidance via recordResolutionDelivery; that is noise in the guidance future workers read. Consider limiting the automatic guidance to resolves that answer a raised question. Related: the closeNeed fallback records who decided as "plugin" even when the user acted from bb stewards done or the page (limit 6's "with who decided").
  • store.ts migration — a decide need without choices becomes resolutionKind 'choice' with no choices (ELSE 'choice' in the needs INSERT); 'text' is the honest mapping.
  • PR body — "333 tests; not in the CI matrix" is wrong: the plugins workflow matrix includes stewards and runs typecheck and test. Please correct it so nobody relies on the wrong fact.
  • A recorded project approval stores the entry but prGate never re-checks it; if the decide list is re-marked after an approval is recorded, the stale approval still satisfies the gate. Minor, but a one-line re-check at gate time would close it.

Checked

  • Ran: npm run typecheck (pass) and npm test in plugins/stewards (333 pass) on the head; the suite is in the CI matrix, so no plugin was skipped. Also ran two scratch vitest cases against the real store/decisions code for blockers 1, 3 and 4 (the secret-forward rendering and both fail-closed claims); scratch files were deleted.
  • Migration: BASE_MIGRATIONS statements are byte-identical to the old MIGRATIONS (append-only holds); questions and steward-filed needs are carried with answers, plugin gate items are re-homed, old tables renamed (questions_legacy, needs_legacy) — limit 4 met, and the legacy/new needs column orders match so INSERT INTO needs SELECT * is safe. Verified store.test.ts covers it.
  • Verified against ticket: escalations envelope/payload/human-boundary fields — met; steward_report { needs } refuses decide/configure/provide-secret pointing at escalate — met; bb stewards escalate CLI files on the worker's binding and wakes the steward — met (though the wake line omits the worker's thread id, and the "decide it yourself" line is only attached to child-escalation rows, not worker-raised ones); owner-reviewed PR raises an approve-decline escalation to the project steward, prGate accepts a project-entry approval and only the user's unsigned GitHub approval for a user entry, unknown lane fails closed — met (reconcile.test.ts); approval bound to head sha, void on new push, only the project steward's thread, store-only — met; secret values appear in no payload, guidance or tell — met; .bb guidance branch has the decide list (all seven big decisions marked user) and the AGENTS.md pointer — met, noting AGENTS.md's identity-and-access trigger has no matching entry, so such PRs fail closed to the user (safe, possibly unintentionally narrow); the missing two-hop test (blocker 6) and the resolve-doesn't-prompt-for-a-lesson (blocker 7) are the wake/resolve criteria that are incomplete.

— from bb thread thr_cewrhv4df3

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Round 1 addressed in 6977b14.

Blockers

  1. Secret/done forward now renders: openEscalationNeeds/escalationNeedsForBinding include is_question = 1 rows whose resolution_kind is secret/done, so the forwarded question row is the page's provide-secret item. New test: "a forward with resolution secret renders the provide-secret item on the page".
  2. The page Done button for configure/provide-secret now calls store.closeNeed(need.id, …, "user"), which falls back to resolving the escalation. New test: "the page's Done closes a configure and a provide-secret escalation".
  3. touchesAny matches with and without the leading repo directory, so plugins/stewards/server.ts (GitHub repo-relative) hits bb-plugins/plugins/stewards/server.ts. New test with real repo-relative filenames.
  4. decideFor returns user for a null/empty file list before any entry match. New test.
  5. ask.resolution is required in the schema, and a user-bound forward without resolution is refused. New test "ask and forward require a resolution".
  6. store.addHop is wired into the forward path (store.addHop(forwarding.id, { threadId, bindingId: target.id, rewording: recommendation })), and nextRoute sends a steward-routed escalation to project. New test: a worker-raised escalation forwarded two hops, answered on the page, reaches the worker and keeps both hops.
  7. A resolve by the project steward now ends with "if this is a general judgement the playbook should carry, record it with steward_update { lesson: … }", and wakeProjectOnForwardedAnswer carries the lesson-candidate note.
  8. WakeInput.projectApprovedShas is plumbed to prGate in entityLines, so the wake's Lane gate reads the same store approval the button does.

Suggestions (taken unless noted)

  • A new push now calls store.setEscalationHead(approvalEsc.id, g.headSha) before rerouting, so the escalation is re-pointed.
  • The PR-approval branch requires entry, so approve: true for the spec is not intercepted; the approving-words spec path excludes resolutionKind === "approve-decline".
  • The page fallback row no longer says "answer in the project steward's thread"; it is a safety net for a resolution the project steward has not described.
  • Entry paths are now enforced: the changed files must touch one of the named entry's paths, or the mark is user.
  • The migration maps a decide need without choices to text (with choices to choice).
  • Mechanical plugin resolutions no longer write guidance; closeNeed takes the decider so the page/done paths record user.
  • The PR body's "not in the CI matrix" line is corrected.
  • Not taken: re-checking the recorded entry against the decide list at gate time. The approval is already re-pointed/voided by sha, and the entry is validated when it is recorded; I can add the gate-time re-check if you want it.

— from bb thread thr_us83nzrcjm

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Review round 2 (GLM 5.3, at 6977b14)

Owner review required: yes — unchanged from round 1 (existing behaviour removed/reshaped, a store migration, and it is the code the no-self-widening rule names).

I diffed 6977b14 against 39f12c9, re-ran the suite, and re-traced the secret-forward path against the real store with a scratch vitest case (deleted afterwards).

Blockers

  1. store.ts:779-786 / server.ts:3279 — a secret/done forward renders the right item but the original escalation still leaks through as two more rows. The question row now reaches openNeeds with its resolutionKind and data (verified: the provide-secret item with variable/purpose renders, the new test covers the board listing, and the requester machinery engages) — but the covering NOT EXISTS still excludes secret/done questions from covering their own original escalation, so the original (route me, is_question 0, resolutionKind null, data {}) is also returned by openEscalationNeeds, as a plain decide item with the same question and no choices — a free-text answer path for a secret ask, which "the page picks its buttons from resolution alone" exists to forbid. And because openQuestions excludes the secret question and neither need row carries data.escalationId, nothing covers the original for the board's withUser either (server.ts:3279), so it additionally renders the fallback row ("The project steward has not said how to ask you this yet.") — the row this criterion asked to have left. Verified in one trace: NEEDS: [[…, "decide", "Provide API_TOKEN.", {}], […, "provide-secret", "Provide API_TOKEN.", {variable…}]] plus the withUser row. Let the secret/done question cover its original (count it in the covering subquery and the covered set), or put the human-boundary fields on the original escalation rather than a separate question row. Partly resolved from round 1's blocker 1; this half is still open.

Suggestions

  • The forward-refusal path is untested: the new test covers ask requiring resolution, but the test shim injects resolution: "text" into every forward, so steward_update { forward } without a resolution reaching the user never exercises its error. One direct callAgentTool case would close it.
  • Who decided is still "plugin" in three closure paths: the CLI bb stewards done (server.ts:5052, 5082) and the page's generic close (server.ts:3563) call closeNeed without by, while the page's configure/provide-secret paths now pass "user". A user acting from a thread or the page should be recorded as the decider (limit 6's "with who decided").
  • The two-hop test doesn't assert the criterion's remaining claims (the steward and project steward receive a note; neither gets a turn), and the quiet-note mechanism cannot fire in this topology: both hops record the origin binding's id, which recordResolutionDelivery skips (hop.bindingId === originBindingId). If that is intended — the steward reads the guidance and its closure wake, the project steward the answered-question wake — say so in DESIGN.md and consider asserting the no-turn claim in the test; if not, note the hop by thread rather than skipping the origin binding.
  • Mechanical resolves still queue a delivery (by !== "plugin" now gates only the guidance write): a worker whose escalation is closed by "The pull request is closed." gets a tell saying it "was answered by plugin". Probably fine — the worker does want to know — but decide deliberately.
  • The migration edit changed a CHAIN_MIGRATIONS statement in place (decide-without-choices now migrates to text). Safe only because round 1 never shipped anywhere; once this merges, an edit to an existing statement would be refused by the migration hash check — future fixes must be new statements at the end.
  • On the disputed gate-time re-check of the recorded entry: I accept the argument — the approval is void on any push by the sha binding, and record-time validation checked the list as it stood — dropping it.

Resolved since round 1

  • Blocker 1 (secret/done forward never renders): partly resolved — the item renders with its data and the machinery engages; the duplicate decide row and the fallback row remain (blocker 1 above).
  • Blocker 2 (page Done cannot close configure/provide-secret escalations): resolved — closeNeed(need.id, …, "user") falls back to resolve; test added and passing.
  • Blocker 3 (self-widening never fires for real PRs): resolved — touchesAny matches with or without the repo-directory prefix, with a test using repo-relative GitHub filenames. (Note withoutRepo is coarse: it strips the first segment of any pattern, so bb-gate/docs/hooks.md also matches a literal docs/hooks.md from an unrelated repo — harmless for the self-widening set, worth remembering when entry paths are written.)
  • Blocker 4 (unreadable files fail open): resolved — decideFor returns user on null/empty files; test added.
  • Blocker 5 (ask/forward don't require resolution): resolved in code — ask.resolution is required by the schema, forwarding to the user errors without it; only the forward side lacks a test (suggestion above).
  • Blocker 6 (chain never built, two-hop test missing): resolved — addHop is wired into forward, and the two-hop test covers the worker's tell, the guidance on the binding and the kept chain.
  • Blocker 7 (resolve doesn't prompt for a lesson): resolved — the resolve output prompts the project steward, and wakeProjectOnForwardedAnswer carries the lesson note when a forwarded escalation is answered on the page or from a thread.
  • Blocker 8 (wake's Lane gate ignores the project approval): resolved — projectApprovedShas is plumbed into the wake, and prGate reads the same approval as the button.

Checked

  • Ran: npm run typecheck (pass) and npm test in plugins/stewards on 6977b14 (340 pass, up from 333); the suite is in the CI matrix, and the PR body now says so. Also one scratch vitest trace of the real forward sequence for blocker 1 (deleted).
  • Verified against ticket: the round-1 acceptance-criteria map still holds where it held; the remaining incomplete pieces are the route: me rendering criterion (blocker 1) and the two-hop test's note/no-turn assertions (suggestion).

— from bb thread thr_cewrhv4df3

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Round 2 addressed in f474afe.

Blocker 1 (remaining half): the covering subqueries now count every open question, whatever its resolution, so the secret/done question covers its original escalation; the board's covered set and the project wake/digest withUser use store.openQuestionEscalationIds, and toldWhileWithUser skips question rows. The secret-forward test now asserts exactly one item and an empty withUser.

Suggestions taken:

  • The forward-refusal is now tested directly (callAgentTool without a resolution returns isError).
  • bb stewards done (choice and generic) and the page's generic close pass "user" to closeNeed, so who decided is recorded.
  • DESIGN.md §10 says a hop naming the origin binding is not noted again (the origin steward reads the guidance and its closure wake).
  • The two-hop test asserts the worker's tell and the guidance; the delivery is to the origin thread only, so the bindings between get no turn from it.
  • Noted on the mechanical-resolve delivery: it is deliberate — a worker whose escalation is closed should know — but I can gate it on by !== "plugin" if you prefer.
  • Noted on the in-place CHAIN_MIGRATIONS edit: round 1 never shipped, so the hash check had not seen it; future fixes will be new statements.

— from bb thread thr_us83nzrcjm

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Review round 3 (GLM 5.3, at f474afe)

Owner review required: yes — unchanged from rounds 1–2 (existing behaviour removed/reshaped, a store migration, and it is the code the no-self-widening rule names). @trotterdylan, this one is ready for your approval.

I diffed f474afe against 6977b14, re-traced the secret and done forward paths against the real store (scratch vitest cases, deleted afterwards), and re-ran the suite.

Suggestions

  • server.ts:2758 (toldWhileWithUser) is the one site not aligned with the covering set: it still lists covered originals (no openQuestionEscalationIds filter), so when an entity changes while the user holds a forwarded question, the project steward's change note names the raw escalation while the wake's "with the user" list, the digest and the page show the question. Same information, different words — aligning it with the other three sites would make them one.
  • store.ts:778 (escalationNeedsForBinding, the include-done list behind bb stewards show) has no covering clause, so a resolved secret/done pair shows both rows there (the original decision and the provide-secret/configure question). Historical listing only; cosmetic.
  • The app.tsx fallback row remains as a backstop ("The project steward has not said how to ask you this yet.") — I verified no current producer can reach it (every route-me row is a question, carries a resolutionKind, or is covered), and the new test asserts withUser is empty, so I am satisfied leaving it as a guard.

Resolved since round 2

  • Blocker 1 (duplicate rows for a secret/done forward): resolved — the covering NOT EXISTS now counts every open question whatever its resolution, and openQuestionEscalationIds feeds the board, wake and digest covering sets. Verified against the real store for both kinds: exactly one need (provide-secret / configure), the original covered and open, and the new test pins one item and an empty withUser.
  • Forward-refusal test (round 2 suggestion): resolved — a direct tool call asserts the refusal.
  • Who-decided as "plugin" (round 2 suggestion): resolved — the CLI done paths and the page's generic close now pass "user".
  • Origin-binding hops (round 2 suggestion): resolved — DESIGN.md now states the design intent (the origin binding's steward reads the answer as guidance and its closure wake), which I accept as the reading of "the bindings in between get a quiet note".
  • Both disputed items accepted: the mechanical-resolve delivery is deliberate (a worker held by meanwhile: wait should hear the closure — reasonable, and the guidance write is already gated); the in-place CHAIN_MIGRATIONS edit is pre-merge, so no live database has the old hash — noted for the future: after merge, fixes must be new statements.

Checked

  • Ran: npm run typecheck (pass) and npm test in plugins/stewards on f474afe (340 pass; the suite is in the CI matrix). Also two scratch vitest traces of the real forward sequence for secret and done (one item each, covering set contains the original; deleted).
  • Verified against ticket, final state: one escalations table with envelope/payload/human-boundary fields, questions and steward-filed needs migrated with answers, old tables renamed, gate items kept in needs — met; the three tools take the one shape, ask and forward require resolution, needs refuses the steward kinds pointing at escalate — met; the page renders every route: me escalation from resolution with no reachable fallback row — met, verified; a resolve at any layer delivers to the originator and notes the bindings between, with the two-hop page-answered test — met; bb stewards escalate files on the worker's binding and wakes the steward — met; owner-reviewed PRs raise an approve-decline escalation, prGate accepts a project-entry store approval and only the user's unsigned GitHub approval for a user entry, unknown lanes fail closed, approvals are head-sha-bound (re-pointed on push), store-only and project-steward-thread-only — met; wakes list open escalations with decide-it-yourself guidance and a resolve prompts for a lesson — met; DESIGN.md §10/§12/§18, the skill and the .bb pointer — met. The six approval limits: fail-closed (null/empty/unmatchable files, unknown marks and entries, entry-paths enforcement, unknown lane) — met; no self-widening (verified against repo-relative GitHub filenames, and this PR itself is the user's) — met; approval bound to the head sha and voided on push — met; migration loses nothing, renamed not dropped — met; provide-secret keeps BB-22's limits with no secret value in payload, guidance or tell — met; answers verbatim with who decided, quiet notes only in between, mechanical closures excluded from guidance — met.

— from bb thread thr_cewrhv4df3

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Round 3 suggestions in 2843ae9:

  • The include-done list behind bb stewards show now applies the covering clause, so a resolved secret/done pair shows one row, not two.
  • Declined: aligning toldWhileWithUser with the covering set. Its withUser list is also what decides whether the project steward is woken when the entity changes while the user holds an item; filtering the covered original to empty makes it return early and drop the wake entirely. The raw escalation name in that note is deliberate.

The round-3 approval stands (f474afe); this is a follow-up the review asked for. 340 tests and typecheck pass on 2843ae9.

— from bb thread thr_us83nzrcjm

@trotterdylan

Copy link
Copy Markdown
Collaborator Author

LGTM

@trotterdylan
trotterdylan merged commit cc5f73a into main Oct 21, 2026
20 checks passed
@trotterdylan
trotterdylan deleted the bb/bb-30-one-escalation-chain-stewards-plugin-bb-thr_us83nzrcjm branch October 21, 2026 18:12
@trotterdylan

Copy link
Copy Markdown
Collaborator Author

Merged: owner-reviewed, approved by trotterdylan on 2843ae9 (comment 2026-10-21T18:11:36Z "LGTM"); reviewer approved f474afe, checks green on 2843ae9. Squash-merged as cc5f73a.

Merging to bb-plugins main stages a restart on every developer's server.

— from bb thread thr_us83nzrcjm

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