Skip to content

bug(cli): capability provider hides MCP server startup failures #4536

Description

@jsiu93

What happened

When a Runtime Host capability provider starts with one healthy MCP server and one missing command, the healthy server publishes its tools and the provider stays running. The only log line is Runtime Host capability provider is connected (24 MCP tools). The failed server name and ENOENT diagnostic are absent.

How to reproduce

  1. Preload the healthy server and create an MCP config:
bunx xcodebuildmcp --version
TMP="$HOME/maka-provider-repro"
mkdir -p "$TMP"
cat > "$TMP/mcp.json" <<'JSON'
{
  "mcpServers": {
    "xcodebuildmcp": {"command":"bunx","args":["xcodebuildmcp","mcp"]},
    "missing-command": {"command":"command-does-not-exist","args":[]}
  }
}
JSON
  1. Start a Runtime Host with maka runtime-host serve, then record its rootId and WebSocket port.
  2. Issue a capability-provider credential:
maka runtime-host access issue \
  --root "$RUNTIME_ROOT" \
  --kind capability-provider \
  --principal repro
  1. Start the provider with the returned credential:
MAKA_RUNTIME_HOST_ACCESS_CREDENTIAL="$CREDENTIAL" \
maka runtime-host capability-provider serve \
  --url "ws://127.0.0.1:$PORT/runtime-host" \
  --mcp-config "$TMP/mcp.json" \
  --expected-root "$ROOT_ID"

The provider reports 24 connected tools; entries for missing-command and ENOENT are absent.

Expected

The readiness line should keep the healthy tool count and include the failed server count, server name, and sanitized startup diagnostic. The healthy server should remain published.

Root cause

packages/mcp/src/index.ts:486 catches each rejected connect() during sync() and retains the sanitized error only in the manager status. packages/cli/src/runtime-host-capability-provider-command.ts:127 builds the readiness line from toolSnapshot().tools.length alone and omits those statuses.

Environment

  • Maka commit: 4cbe224
  • OS: macOS 26.6.1
  • Surface: Runtime Host capability-provider CLI
  • Node.js: 24.19.0

Activity

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