opencode mcp list hangs when plugins are enabled; --pure completes
Summary
opencode mcp list hangs indefinitely with plugins enabled. The same command with --pure finishes in a bounded time and lists servers, including a remote HTTP MCP that is connected.
Observed: hang longer than 80s; a 22s timeout was not enough to complete the plugin-enabled path.
Reproduction
- Enable plugins (default / non-pure mode).
- Run
opencode mcp list.
- Observe: the command never returns (waited >80s).
- Run
opencode --pure mcp list.
- Observe: completes in under 20s. The intended remote HTTP MCP is connected. Other unrelated servers fail with SSE
Non-200 403. Listing still completes.
No custom MCP URLs or credentials are required to discuss the hang: the --pure run already shows mixed success/failure without blocking.
Expected
mcp list should:
- Apply a per-server connect timeout (including HTTP and SSE transports).
- Continue listing remaining servers if one server is slow, unauthenticated, or returns 403.
- Never wait forever on a single plugin hook or MCP handshake.
--pure currently unblocks listing; the plugin-enabled path should be equally bounded.
Hypothesis
Plugin-enabled mcp list waits forever on a slow or auth-failing MCP (or a plugin hook that talks to one) instead of enforcing per-server timeouts. --pure skips that path, so mixed SSE 403s do not stall the command.
Ask
- Per-server connect timeout on
mcp list (plugin-enabled and --pure).
- One failed or hung server must not block listing the rest.
- If a plugin hook participates in MCP discovery, it should inherit the same timeout and isolation.
Environment (anonymized)
- OpenCode CLI (
opencode mcp list / opencode --pure mcp list)
- Mix of remote HTTP MCP and SSE servers
- Plugins enabled vs
--pure
opencode mcp listhangs when plugins are enabled;--purecompletesSummary
opencode mcp listhangs indefinitely with plugins enabled. The same command with--purefinishes in a bounded time and lists servers, including a remote HTTP MCP that is connected.Observed: hang longer than 80s; a 22s timeout was not enough to complete the plugin-enabled path.
Reproduction
opencode mcp list.opencode --pure mcp list.Non-200403. Listing still completes.No custom MCP URLs or credentials are required to discuss the hang: the
--purerun already shows mixed success/failure without blocking.Expected
mcp listshould:--purecurrently unblocks listing; the plugin-enabled path should be equally bounded.Hypothesis
Plugin-enabled
mcp listwaits forever on a slow or auth-failing MCP (or a plugin hook that talks to one) instead of enforcing per-server timeouts.--pureskips that path, so mixed SSE 403s do not stall the command.Ask
mcp list(plugin-enabled and--pure).Environment (anonymized)
opencode mcp list/opencode --pure mcp list)--pure