xiaozhu1337's remote MCP servers are slow but healthy: initialize took
0.6-12s, notifications/initialized 0.7-3.5s and tools/list 38-53s. The
check had one 15s budget for all of it (checkTimeout), so every such
server showed "no answer", and CheckServers kept that first result for
the session.
Now each step (initialize, notifications/initialized, tools/list; connect
for an SSE server's stream) has a budget of its own: remoteStep 60s for a
URL, stdioStep 30s for a command (was 15s for the whole check). The timer
is reset as each step starts (stepTo). A timeout says its Step and how
long it Waited (ms), and the row reads "no answer to tools/list", the
tooltip "No answer to tools/list in 60 seconds". A timeout isn't kept,
and it drops an earlier answer kept for the server, so the next look (or
a click on the status, as before) asks again. Strings in en, zh, zh-TW,
ja and de; the old "No answer in 15 seconds" is gone. No per-server
setting: the per-step budget covers the reported timings.
Run:
- TestCheckSlowRemoteServer, TestCheckTimeoutNamesTheStep,
TestCheckTimeoutAskedAgain (new): fail on the old code (one budget:
the 2.9s server times out at initialize; the step is always
initialize; a timeout, and an earlier ok after a fresh timeout, are
served from the cache), pass now. The rest of TestCheck* pass.
- go test -tags nogui ./... under a temp HOME: all ok.
- gofmt -l: clean. go vet (darwin, GOOS=linux, GOOS=windows) on
internal/library and internal/gui: clean.
- GUI: library-mcp-health (status names the step, stays one line within
220px), i18n-keys, gui-ja, gui-de in Chromium and WebKit: 13/13 pass.
- Real use: `magpie web` on 127.0.0.1:3783 under a scratch HOME, a
library server on a fake streamable HTTP MCP on 3784.
POST /api/library/mcp/check: at 8s/2s/45s it is ok with 7 tools
(55s); with tools/list at 70s it is timeout, step tools/list, waited
60000 (62s); then at the reporter's slowest 12s/3.5s/53s a non-fresh
check asked it again and got ok with 7 tools (68s).