Symptoms: The agent doesn't wake up; logs show cdp_not_found.
Cause: VS Code was started without the remote debugging port.
Fix:
- Close VS Code entirely.
- Run in terminal:
code --remote-debugging-port=9000 - Verify:
curl http://127.0.0.1:9000/json/listshould return JSON.
Symptoms: Bridge logs show the target was found, but editor_not_found.
Cause: The script cannot locate the Lexical editor DOM element (possibly due to UI changes or iframe issues).
Fix:
- Ensure the Chat view is Visible (not collapsed).
- Check
scripts/poke.mjsupdates (the "Shotgun" approach usually fixes this).
Symptoms: The phone UI is 404.
Cause: Missing public/index.html.
Fix: Ensure public/index.html exists in the repo root.
Symptoms: You are idle, but logs say "Agent busy". Cause: The "Cancel" button (or its tooltip) is falsely detected. Fix:
- Manually type something in the chat and clear it.
- Restart the bridge:
npm start.
Visit http://localhost:8787/status to see real-time health:
cdp.connnection: Should be ok.agent.last_seen: Should be recent.
Check .logs/ag-bridge-YYYY-MM-DD.log for detailed traces.