From 0ba7e90c9ec3478c733b01b8f9d2133af26e853f Mon Sep 17 00:00:00 2001 From: dadachi Date: Sun, 24 May 2026 17:50:40 +0900 Subject: [PATCH] fix(plugin): pin bundled mobile-mcp to 0.0.54 (0.0.55+ closes stdio) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The bundled mobile-mcp server (and the user's identical global one) showed ✘ failed in /mcp: mobile-mcp 0.0.55+ closes the stdio connection on startup (observed: "Connection closed" ~6s in, zero output), so `@latest` (now 0.0.56) never completes the MCP handshake. 0.0.54 starts cleanly ("mobile-mcp server running on stdio" + valid initialize response) — verified with a live handshake. This is the same conclusion the agent core already reached: src/mobile.ts pins DEFAULT_ARGS to @mobilenext/mobile-mcp@0.0.54 "(was @latest). mobile-mcp 0.0.55+ closes the stdio …". The plugin now matches that pin. Side benefit: pinning makes the bundled command differ from a typical global `@latest` mobile-mcp config, so Claude won't dedup the broken global over our working bundled one. Note (out of scope, separate): CLAUDE.md's Stack section still lists `npx -y @mobilenext/mobile-mcp@latest`, which is stale/misleading given this pin. Co-Authored-By: Claude Opus 4.7 (1M context) --- plugin/.mcp.json | 2 +- plugin/README.md | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/plugin/.mcp.json b/plugin/.mcp.json index 9aa431b..29571ab 100644 --- a/plugin/.mcp.json +++ b/plugin/.mcp.json @@ -6,7 +6,7 @@ }, "mobile-mcp": { "command": "npx", - "args": ["-y", "@mobilenext/mobile-mcp@latest"] + "args": ["-y", "@mobilenext/mobile-mcp@0.0.54"] } } } diff --git a/plugin/README.md b/plugin/README.md index e44aa1b..9d1e9e8 100644 --- a/plugin/README.md +++ b/plugin/README.md @@ -33,7 +33,7 @@ plugin/ - **Bundled MCP servers** (`/mcp` to check): the generator server (`nativeapptemplate-agent`, wired as `npx -y -p nativeapptemplate-agent@latest nativeapptemplate-agent-mcp`) and - `mobile-mcp` (`@mobilenext/mobile-mcp`) for device automation. + `mobile-mcp` (`@mobilenext/mobile-mcp@0.0.54`) for device automation. Two non-obvious bits in that generator command: the MCP entry point is a **bin** of the `nativeapptemplate-agent` package, not its own package, so `-p` is @@ -42,6 +42,12 @@ plugin/ own repo (cwd shadowing) and fails with `command not found`. `@latest` forces registry resolution regardless of cwd. + `mobile-mcp` is **pinned to 0.0.54** on purpose: 0.0.55+ closes the stdio + connection on startup (`Connection closed` ~6s in), so `@latest` fails. This + matches the agent's own pin in `src/mobile.ts`. If you have a global `mobile-mcp` + config on `@latest`, it'll show ✘ failed in `/mcp` — this bundled, pinned one is + the working copy (different command, so it won't dedup against your global). + ## Requirements - Node.js 22+ and an `ANTHROPIC_API_KEY` with access to `claude-opus-4-7`.