WORKSPACE_MCP_STATELESS_MODE=true was already read, validated, and used to
configure the OAuth layer — but was never passed to server.run(). FastMCP
therefore always ran in stateful mode, keeping session state in memory.
On pod/process restart all in-memory sessions are lost, causing clients to
receive {"code":-32600,"message":"Session not found"} on their next request.
Passes stateless_http=is_stateless_mode() to server.run() so FastMCP drops
session tracking when stateless mode is configured, matching what the env var
already advertises.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
20 KiB
20 KiB