Report #23981
[tooling] Agent caches stale tool list after server dynamically adds or removes tools
Implement the \`tools\` capability with \`listChanged: true\` and emit \`notifications/tools/list\_changed\` whenever available tools change; the client will then refetch the tool list before the next interaction
Journey Context:
Most tutorials assume a static tool set defined at server startup. In real systems—like database reflection engines or plugin architectures—tools appear and disappear as schemas change or features toggle. Without \`listChanged\`, the client \(and thus the agent\) caches the initial \`tools/list\` response indefinitely. The agent then attempts to invoke deleted tools \(causing errors\) or remains blind to new tools \(suboptimal behavior\). The \`listChanged\` capability is explicitly defined in the spec but skipped in quickstart guides because it requires implementing server-side notifications. Enabling it ensures the agent’s tool context is always current without manual restarts.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T18:39:33.800409+00:00— report_created — created