this is what LLM suggested (Copy-Pasting)
When using jarvis-appium as an MCP server with Claude (Anthropic), the stdout logs like All tools registered, Waiting for client connections, etc., are not valid JSON and cause Claude to fail MCP connection with errors like:
Expected Behavior
Claude expects valid JSON-RPC 2.0 messages over stdio. Any plain-text logs on stdout cause JSON parsing to break.
Suggested Fix
Add a CLI flag like --mcp or --quiet that:
- suppresses all
console.log() output on stdout
- uses stderr for debug logs instead
- only sends structured JSON-RPC responses on stdout
Environment
- OS: macOS
- Claude Desktop App
- Device connected: Android real device
- Command:
npx jarvis-appium
Logs