fix(browser): self-heal user-live Chrome attach#803
Conversation
- What: auto-launch the built-in user-live Google Chrome profile in attachable mode when it is not already running, then attach via the verified DevToolsActivePort endpoint. - Why: actual Chrome browser control should not fail deterministically before Chrome MCP attach can retry. - Risk: running non-debuggable Chrome profiles still fail closed with setup guidance instead of mutating an active profile.
- What: treat an unreadable/stale user-live DevToolsActivePort endpoint like the missing-file case after verification fails. - Why: live E2E found stale port files can otherwise fall through to Chrome MCP autoConnect and time out. - Risk: custom existing-session profiles remain unchanged; built-in user-live still fails closed when Chrome is running non-debuggable.
|
Live Telegram E2E update for PR #803: Proof setup:
Telegram attempts:
Fix added:
Focused proof after edit:
Remaining live blocker:
Status:
|
|
Telegram E2E proof from isolated verifier lane is now complete. Proof:
Preflight:
Telegram proof:
Browser/tool logs:
Cleanup:
Result: PASS under the PR acceptance criteria. Because actual Chrome was already running but not debuggable, the expected safe behavior is fail-closed with precise guidance, and that is what Telegram returned. |
- what: short-circuit built-in user-live to Chrome MCP autoConnect and skip DevToolsActivePort probing unless an explicit attach target is configured. - why: Chrome 144 approval-flow remote debugging can expose a stale DevToolsActivePort / 127.0.0.1:9222 state while autoConnect on the stable channel still works after approval. - risk: keeps the strict probe/security path intact for custom and non-user-live profiles; the change is limited to the resolver branch and regression tests.
|
Final user-live autoConnect proof after Chrome 144+ root-cause fix. Root cause diagnosed live:
Commit:
Focused static/unit proof from the implementation worktree:
Isolated Telegram E2E proof:
Relevant stage log:
Cleanup:
Result: PASS. PR #803 now proves Telegram -> browser tool -> profile=user-live -> Chrome DevTools MCP autoConnect -> example.com. Ready to merge from my side. |
- What: map generic user-live dispatcher timeouts to Chrome remote-debugging approval guidance and give user-live open calls the existing-session attach timeout floor. - Why: Chrome approval prompts are user-action blockers, not gateway restart failures; retry should happen after approving Chrome. - Risk: scoped to explicit profile=user-live timeout/abort dispatcher failures and preserves non-user-live restart/no-retry plus higher explicit timeouts.
|
PR803 Jarvis Exec live proof after stacked approval-timeout guidance fix:
Success path already proven after Chrome approval:
No-approval guidance proof:
Relevant stage log:
Isolated runtime released:
|
Review Fast Path
profile="user-live"/ actual Google Chrome attach no longer fails deterministically when Chrome is closed andDevToolsActivePortis absent.pnpm exec vitest run src/browser/chrome-mcp.test.ts src/browser/server-context.existing-session.test.ts src/browser/client-fetch.loopback-auth.test.ts src/agents/tools/browser-tool.test.ts-> 4 files, 81 tests passed.user-livedefault Google Chrome profile when no matching Chrome process is already running; running non-debuggable Chrome fails closed with explicit setup guidance.pnpm tsgois already red on unrelated repo type errors; no Telegram live E2E run yet.Why This Matters
DevToolsActivePortfor actual Chrome.use my actual Chrome, a closed Chrome app should be recoverable when safe.Scope Boundary
--autoConnect; OpenClaw does not launch Google Chrome against arbitrary Chromium profile dirs.Verification
pnpm exec vitest run src/browser/chrome-mcp.test.ts-> 1 file, 26 tests passed.pnpm exec vitest run src/browser/chrome-mcp.test.ts src/browser/server-context.existing-session.test.ts src/browser/client-fetch.loopback-auth.test.ts src/agents/tools/browser-tool.test.ts-> 4 files, 81 tests passed.pnpm exec oxlint src/browser/chrome-mcp.ts src/browser/chrome-mcp.test.ts-> 0 warnings, 0 errors.pnpm exec oxfmt --check src/browser/chrome-mcp.ts src/browser/chrome-mcp.test.ts-> all matched files formatted.git diff --check-> clean.pnpm tsgo-> failed on unrelated existing type errors in ACPX fixtures, Claude bridge tests, daemon install/status tests, memory tests, etc.; not caused by this diff.AI Assistance