Device Connection Issues
No Device Found
Symptoms
Symptoms
- Error:
DeviceNotFoundError: No device found. Exiting. - Agent initialization fails
Solutions
Solutions
1. Verify device connectionYou should see your device listed with status “device”2. Enable USB debugging (Android)5. Specify device manually
- Android
- iOS
- Settings → About Phone → Tap “Build Number” 7 times
- Settings → Developer options → USB debugging
- Unlock your device
- Tap “Trust” when prompted
USB Connection Unstable
Symptoms
Symptoms
- Random disconnections during automation
adb: error: device 'xxx' not found
Solutions
Solutions
1. Use a high-quality USB cablePoor quality cables can cause intermittent connections.2. Connect directly to computerAvoid USB hubs which can cause instability.3. Increase ADB timeout4. Use wireless debugging
Ensure stable Wi-Fi connection for wireless debugging.
Server-Related Issues
Servers Fail to Start
Symptoms
Symptoms
ServerStartupErrorduring initialization- Ports already in use
- Zombie processes from previous runs
Solutions
Solutions
1. Force clean zombie servers2. Check if Maestro is installedIf not installed, follow: https://maestro.mobile.dev/getting-started/installing-maestro3. Use custom ports4. Check for port conflicts
Task Execution Issues
Agent Not Initialized
Symptoms
Symptoms
- Error:
AgentNotInitializedError
Solution
Solution
Always call
agent.init() before running tasks:Task Times Out or Fails
Symptoms
Symptoms
- Task gets stuck or fails to complete
- Reaches max_steps limit
- Unexpected results
Solutions
Solutions
1. Simplify the task goalBreak complex tasks into smaller steps:2. Increase max_steps limit3. Enable tracing to debug4. Be more specific in goals
Incorrect Task Results
Symptoms
Symptoms
- Task returns unexpected or incomplete data
- Structured output fields are missing or incorrect
Solutions
Solutions
1. Use structured output with clear descriptions2. Provide more context in the goal3. Use better LLM models for cortex
LLM and API Issues
API Key Authentication
Symptoms
Symptoms
- Authentication errors
openai.error.AuthenticationErroror similar- 401 Unauthorized responses
Solutions
Solutions
1. Verify API keys in .env file2. Load environment variablesThe SDK automatically loads 3. Check API key validityTest your keys directly:
.env
.env files, but you can also set manually:Rate Limiting
Symptoms
Symptoms
- 429 Too Many Requests errors
- Tasks slow down over time
Solutions
Solutions
1. Use different providersDistribute load across multiple LLM providers:2. Use tier limitsCheck your API tier limits and upgrade if needed.3. Add delays between tasks
System Environment Issues
Python Version Compatibility
Symptoms
Symptoms
- Import errors or syntax errors
SyntaxErrororModuleNotFoundError
Solution
Solution
Ensure you’re using Python 3.12 or higher:Create compatible environment:
- UV (Recommended)
- venv
Import Errors
Symptoms
Symptoms
ModuleNotFoundError: No module named 'minitap'- Import errors for SDK components
Solutions
Solutions
1. Verify installation2. Reinstall the SDK3. Check virtual environmentEnsure you’re in the correct virtual environment:
Debugging Best Practices
Enable Comprehensive Logging
Use Trace Recording
Always enable tracing during development:Check Trace Contents
After a failed task, examine the traces:Getting Help
Filing a Bug Report
When filing an issue, include:1
Environment Information
2
Device Details
- Platform (Android/iOS)
- Device model
- OS version
3
Minimal Reproduction
Provide a minimal code sample that reproduces the issue
4
Error Messages
Full error traceback and logs
5
Traces (if applicable)
Include relevant screenshots from trace recording
Quick Reference
Clean zombie servers
Clean zombie servers
Check device connection
Check device connection
Enable debug logging
Enable debug logging
Enable tracing
Enable tracing
Reset ADB
Reset ADB