Skip to content

fix(mcp): reconnect on terminated sessions#19232

Closed
LeonSGP43 wants to merge 1 commit into
NousResearch:mainfrom
LeonSGP43:fix/mcp-session-terminated-18790
Closed

fix(mcp): reconnect on terminated sessions#19232
LeonSGP43 wants to merge 1 commit into
NousResearch:mainfrom
LeonSGP43:fix/mcp-session-terminated-18790

Conversation

@LeonSGP43
Copy link
Copy Markdown
Contributor

Fixes #18790\n\n## Summary\n- Treat MCP Session terminated errors as transport-session expiry signals.\n- Reuse the existing reconnect-and-retry path instead of surfacing a hard tool failure.\n- Add a focused regression assertion for the Playwright MCP wording reported by gateway users.\n\n## Verification\n- scripts/run_tests.sh tests/tools/test_mcp_tool_session_expired.py (17 passed, 4 warnings)\n- git diff --check

@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/tools Tool registry, model_tools, toolsets tool/mcp MCP client and OAuth labels May 3, 2026
@alt-glitch
Copy link
Copy Markdown
Collaborator

Related to #18069 and #18143 — overlapping fix for 'Session terminated' MCP error recognition. Check for redundancy with those PRs.

@alt-glitch
Copy link
Copy Markdown
Collaborator

Related to #18069 and #18143 — overlapping fix for 'Session terminated' MCP error recognition.

@teknium1
Copy link
Copy Markdown
Contributor

teknium1 commented May 3, 2026

Salvaged via #19380 onto current main — your commit's authorship was preserved. Thanks @LeonSGP43!

@teknium1 teknium1 closed this May 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/tools Tool registry, model_tools, toolsets P2 Medium — degraded but workaround exists tool/mcp MCP client and OAuth type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: ERROR tools.mcp_tool: MCP tool playwright/browser_run_code call failed: Session terminated - From Gateway sessions

3 participants