Repository navigation
Commit ca4595d
committed
fix(server): resumed Claude sessions wait for their MCP servers
After an idle release, the next turn resumes the Claude session in a new
process. Claude Code connects MCP servers without blocking, so the first
request went out before they were ready, and Claude Code told the agent
every MCP server and connector had disconnected, then reconnected later in
the same turn.
Resumed queries now start with MCP_CONNECTION_NONBLOCKING=0, so Claude Code
waits (up to its connect timeout) for the servers before the first request.
An explicit value in the instance environment still wins.
Fixes #30141
AI-assisted; verified with the tests and tools listed above.1 parent a18a458 commit ca4595d
2 files changed
Lines changed: 33 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
344 | 344 | | |
345 | 345 | | |
346 | 346 | | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
347 | 363 | | |
348 | 364 | | |
349 | 365 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1841 | 1841 | | |
1842 | 1842 | | |
1843 | 1843 | | |
1844 | | - | |
| 1844 | + | |
| 1845 | + | |
1845 | 1846 | | |
1846 | 1847 | | |
1847 | 1848 | | |
1848 | 1849 | | |
| 1850 | + | |
1849 | 1851 | | |
1850 | | - | |
1851 | | - | |
1852 | | - | |
1853 | | - | |
1854 | | - | |
| 1852 | + | |
| 1853 | + | |
| 1854 | + | |
| 1855 | + | |
| 1856 | + | |
| 1857 | + | |
| 1858 | + | |
| 1859 | + | |
1855 | 1860 | | |
1856 | 1861 | | |
1857 | | - | |
| 1862 | + | |
| 1863 | + | |
| 1864 | + | |
| 1865 | + | |
| 1866 | + | |
1858 | 1867 | | |
1859 | 1868 | | |
1860 | 1869 | | |
| |||
11786 | 11795 | | |
11787 | 11796 | | |
11788 | 11797 | | |
| 11798 | + | |
11789 | 11799 | | |
11790 | 11800 | | |
11791 | 11801 | | |
| |||
0 commit comments