feat: add --timeout/-t flag for initialization timeout#87
feat: add --timeout/-t flag for initialization timeout#87natsirtguy wants to merge 1 commit intof:masterfrom
Conversation
|
Fixed lint issues introduced by this PR (gofmt formatting, empty-block). Note: The golangci-lint CI check was already failing on main/master before this PR (see run 19383105784). This PR actually reduces the total issue count from 11 to 8 by fixing formatting issues in files I touched. The remaining 8 issues are pre-existing in the codebase (goconst in web.go, gocritic in new.go, gocyclo in call.go, gofmt in transport_test.go, revive in test_helpers.go). |
Adds a configurable timeout for MCP server initialization: - Default remains 10 seconds (matching current behavior) - Can be set via --timeout or -t flag - Includes tests for timeout flag parsing
d8ebcce to
7c5e248
Compare
|
I rebased onto the commit that fixes the pre-existing linting issues, so should be good to go now. I also changed the default back to 10 seconds to maintain behavior. |
|
@natsirtguy can we merge this? |
I don't know why recheck merge status isn't working. I'll try to figure this out tomorrow. |
Adds a configurable
--timeout/-tflag for MCP server initialization timeout.Default is 30 seconds. Useful when connecting to slow-starting servers.
Changes
FlagTimeout/FlagTimeoutShortconstants andInitTimeoutvariable inroot.goutils.goandcall.goCreateClientFunc()for initialization timeoutUsage