Description
Summary
With the claude-code provider, a resident session can come up without the bb-bridge MCP server (all plugin agent tools and update_environment_directory missing) and never get it back on later turns. Only bb thread stop <id> followed by a new turn restores it.
What happened (bb-app 0.46.1, macOS, Claude Code 2.1.304)
- A thread was idle; a queued
--send-atmessage woke it. - In the same seconds a third-party plugin that contributes agent tools was reinstalled from a new local path (
bb plugin install path:<new> --yes; server log:plugin <id> source moved from path:... to path:...). - The turn started a fresh resident session (turn id prefix changed). Claude Code transcript shows at that moment all MCP servers removed and, 6 s later, all re-added except
bb-bridge(deferred_tools_deltaremovedNames includemcp__bb-bridge__*, the following addedNames don't). - The next turns on the same thread (10 and 30 min later) still had no
bb-bridge:ToolSearch select:mcp__bb-bridge__task_submit→ no match. The plugin itself wasrunning; other threads had the tools. bb thread stop <id>+ new message → tools are back. Also works from inside the thread: queuebb thread tell $BB_THREAD_ID --send-at <+1m> ..., thenbb thread stop --self.
Likely cause
In provider-claude-code/dist/host.js, attachThreadSession builds mcpServers = { "bb-bridge": ... } only when dynamicTools.length > 0 at attach time, presumably empty while the plugin was reloading. startTurn updates env/chrome/1M-context settings on the resident session but never compares dynamicTools, so a session attached with an empty or stale tool set keeps it until the runtime is released.
Expected
On each turn, if the thread's dynamic tool set differs from the one the resident session was built with, refresh bb-bridge (setMcpServers) or set restartBeforeNextTurn, the same way it's done for execution-setting changes. Tool-set changes from plugin install/reload/update would then reach live sessions.
Activity
bb-slop-cop commentedon Oct 20, 2026
🚨 SLOP COP 🚨 ·
new-issue-autopilotproviders,host,provider-claude-code,partial-repro.dynamicToolsto the runtime. Claude already compares tool snapshots and rebuilds on explicit resume.SawyerHood commentedon Oct 20, 2026
Cross-linked the verified resident-refresh evidence into #3626, the older Claude catalog-loss tracker, to coordinate implementation rather than create competing refresh fixes.
These are not confirmed exact duplicates: #3626 starts with reconnect/compaction and has an unresolved initial-loss mechanism; this report starts with reload/session attachment. #5479 reports a stale schema even after stop/resume (unlike this report's working stop workaround), and #5359 covers ACP live updates without rebuilding. Keep those separate acceptance cases. This issue remains open; no fix is claimed.