Skip to content

stewards: load on the bb-server image again, and archive a steward whose last turn outran its ending - #40

Merged
trotterdylan merged 1 commit into
mainfrom
bb/this-thread-is-done-shouldn-t-it-be-archived-inv-thr_vv9xx7xk4i
Oct 20, 2026
Merged

trotterdylan merged 1 commit into
mainfrom
bb/this-thread-is-done-shouldn-t-it-be-archived-inv-thr_vv9xx7xk4i

Conversation

@trotterdylan

Copy link
Copy Markdown
Collaborator

Why

The stewards plugin is in an error state on every developer's bb-server that has restarted onto image 1438:

host.ts:5:92: ERROR: [plugin: provide-public-host-sdk-runtime] "@get-bb/plugin-sdk/host" is not installed for this plugin (no node_modules/@get-bb/plugin-sdk)

host.ts (added by BB-9, #26) imports @get-bb/plugin-sdk/host, but the SDK was only a devDependency, and docker/bb-server/Dockerfile installs plugin deps with --omit=dev. While it is down no steward is woken and no ticket or PR is managed.

Separately, BB-9's own steward (thr_72ybjk6nbc) was never archived when its binding ended. finishEnding skips the archive while the thread is busy, and its wrap-up turn was still running when the ending arrived eight seconds later. Nothing retried: thread-briefs is told not to archive stewards, and the idle handler returned on an ended binding.

What

  • @get-bb/plugin-sdk moves to dependencies (lockfile regenerated). Verified with npm ci --omit=dev into a scratch dir: node_modules/@get-bb/plugin-sdk is present.
  • finishEnding records archiveWhenIdle when the thread is busy instead of dropping the archive; the thread.idle that ends that turn archives it. One-shot, so an owner who writes to the ended steward later is not archived under.
  • Regression test in server.test.ts.

Lane

No-review: a narrow fix that makes stewards do what it was already meant to do (load, and archive its ended steward). No contract, access or infrastructure files touched.

Shipping

Merging moves the bb-gate pin, builds a new bb-server image and stages a restart for every developer's server (Restart now, or the 03:00–05:00 US Eastern window). Until a server restarts onto it, its stewards plugin stays down.

npm run typecheck and npm test (224 tests, 10 files) pass in plugins/stewards.

🤖 Generated with Claude Code

…ose last turn outran its ending

Two fixes to how a steward thread ends up in the sidebar.

The plugin failed to build on every bb-server pod restarted onto
image 1438: host.ts (BB-9) imports @get-bb/plugin-sdk/host, but the SDK
was only a devDependency, and the image installs plugins with
--omit=dev. It is a runtime dependency now, as in multi-repo, the other
live plugin with a host entry.

finishEnding skips the archive when the steward thread is busy, and
nothing retried it, so a steward whose wrap-up turn was still running
when its binding ended (BB-9's was, by eight seconds) stayed in the
sidebar for good: thread-briefs never archives a steward, and the idle
handler returns on an ended binding. finishEnding now records
archiveWhenIdle, and the idle that ends that turn archives the thread.
Once only, so an owner writing to the ended steward later is not
archived under.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@trotterdylan
trotterdylan merged commit d6f70e4 into main Oct 20, 2026
18 checks passed
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