-
Notifications
You must be signed in to change notification settings - Fork 374
Error: WebDriverAgent is not running on simulator + No mention On wiki #233
Description
Describe the bug WebDriverAgent fails to connect to iOS Simulator when attempting to take screenshots or interact with the UI through the mobile-mcp server, even though the simulator is running and accessible.
Configuration (please complete the following information):
Agent: Claude Code (CLI)
OS: Mac (Darwin 24.6.0)
Device used: iOS Simulator
Device version: 18.7.1
Device model: iPhone 16 Pro
To Reproduce Steps to reproduce the behavior:
- Start iOS Simulator with device "iPhone 16 Pro"
- Use mobile-mcp tool mobile_list_available_devices - successfully returns [iPhone 16 Pro]
- Use mobile-mcp tool mobile_take_screenshot with device parameter "iPhone 16 Pro"
- See error: "WebDriverAgent is not running on simulator, please see https://github.com/mobile-next/mobile-mcp/wiki/"
5. No mention of WebDriverAgent on wiki
Expected behavior The mobile_take_screenshot tool should either:
- Automatically start WebDriverAgent if it's installed but not running, OR
- Provide clearer error messaging about how to start WebDriverAgent, OR
- Fall back to native iOS Simulator screenshot capabilities (simctl io screenshot) that don't require WebDriverAgent
Additional Context
The simulator is confirmed running (device list works)
WebDriverAgent/Appium may not be installed on the system
The error message points to wiki but doesn't provide inline guidance
Other mobile-mcp tools like mobile_list_available_devices work correctly
The mobile-mcp server is successfully connected and operational
Possible Solutions
- Add a health check command to verify WebDriverAgent is running before attempting operations
- Provide better error messaging with installation instructions
- Consider using xcrun simctl io as a fallback for basic screenshot functionality on iOS simulators
- Add automatic WebDriverAgent startup if installed but not running