Skip to content

Desktop v1.15.13: MCP UI shows '未配置 MCPs' despite MCP server running (CLI mcp list shows connected) #30366

Closed

Description

@zico00

Describe the Bug

After configuring an MCP server (Open Design MCP, stdio local type) in ~/.config/opencode/opencode.json, the OpenCode Desktop app (v1.15.13, macOS) shows "未配置 MCPs" (MCP not configured) in the MCP status popover and the MCP dialog, despite the MCP server process being started and functional.

To Reproduce

  1. Add a local MCP server to ~/.config/opencode/opencode.json:
{
  "mcp": {
    "my-server": {
      "type": "local",
      "command": ["/path/to/node", "/path/to/mcp-server", "mcp"],
      "enabled": true
    }
  }
}
  1. Restart OpenCode Desktop (fully quit with Cmd+Q and reopen)
  2. Observe: status popover MCP tab shows "未配置 MCPs"
  3. Run opencode mcp list in terminal → shows connected

Expected Behavior

The desktop UI should show the configured MCP server with its connection status (connected/failed/etc), matching the CLI output.

Actual Behavior

Desktop UI shows "未配置 MCPs" in both the status popover and MCP settings dialog, even though the MCP server process is running and connected.

Evidence

  • opencode mcp list CLI output:
┌  MCP Servers
│
●  ✓ open-design connected
│      /Applications/.../node /Applications/.../daemon-cli.mjs mcp
│
└  1 server(s)
  • MCP process confirmed running on system (PID verified, parent PID = desktop sidecar)
  • MCP tools respond correctly to JSON-RPC requests
  • Config file validated via schema (mcp.{name}.type=local, command array, enabled=true)
  • Sidecar server log shows no MCP-related errors
  • Renderer log only has ResizeObserver warnings, no MCP errors

Environment

  • OpenCode Desktop version: 1.15.13 (packaged)
  • macOS version: macOS (Apple Silicon)
  • Install method: Desktop DMG download from opencode.ai
  • ~/.config/opencode/opencode.json verified correct
  • User data dir: ~/Library/Application Support/ai.opencode.desktop

Possible Root Cause

The UI reads MCP status from sync.data.mcp, populated by the desktop sidecar server process. The sidecar starts the MCP server process correctly (confirmed via process tree), but the MCP status may not be propagating to sync.data.mcp that the renderer UI reads. CLI opencode mcp list works because it directly reads the config and probes the MCP server independently. Clearing ~/Library/Application Support/ai.opencode.desktop/opencode/ cache did not resolve the issue.

Activity

  1. zico00 commented on Jun 2, 2026

    @zico00
    Author

    Update: Further Investigation

    Key findings after deeper debugging:

    1. environment vs env fix confirmed - The config key must be "environment" (not "env"). The McpLocalConfig schema only recognizes "environment". When "env" was used, the environment variables were silently dropped.

    2. After fix: env vars are correctly passed - MCP process now receives OD_SIDECAR_IPC_PATH and OD_DATA_DIR as expected.

    3. MCP process hierarchy confirmed correct:

      OpenCode Desktop (PID 1105)
        └── NodeService utility/sidecar (PID 1134)
              └── MCP process (PID 1239)
      

      The desktop sidecar correctly spawns the MCP process and passes environment variables.

    4. MCP server responds correctly - All 8 tools (list_projects, get_file, search_files, create_artifact, etc.) respond to JSON-RPC requests.

    5. Desktop UI still shows "未配置 MCPs" despite all of the above being functional.

    Conclusion

    The MCP server is fully functional - the sidecar reads the config, starts the process, passes environment variables, and the MCP server connects to the daemon. The CLI opencode mcp list confirms connected.

    The only remaining issue is the UI renderer not reflecting MCP state - sync.data.mcp is either not being populated or not synced to the renderer process. This appears to be a frontend-side sync/state bug specific to the Desktop app (v1.15.17).

  2. github-actions commented on Jun 2, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

  3. Hona commented on Jun 4, 2026

    @Hona
    Member

    Fixed in next version

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions