openclaw - ✅(Solved) Fix [Bug]: Chrome MCP existing-session status exposes no page-tool readiness signal [1 pull requests, 1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#80268Fetched 2026-05-11 03:16:59
View on GitHub
Comments
1
Participants
2
Timeline
8
Reactions
2
Author
Timeline (top)
referenced ×6commented ×1cross-referenced ×1

For Chrome MCP existing-session profiles (e.g. --browser-profile user), openclaw browser status exposes only transport-handshake fields (cdpHttp, cdpReady). It does not surface whether a page-level Chrome MCP tool round-trip (list_pages, etc.) actually succeeds. Operators and downstream tooling have no honest signal to distinguish "transport handshake passed" from "page tools are usable."

Root Cause

  1. On macOS, open Chrome and enable remote debugging via chrome://inspect/#remote-debugging → toggle Allow remote debugging for this browser instance ON. Confirm port 9222 is listening (netstat -an | grep 9222).
  2. Run openclaw browser --browser-profile user status. Inspect the JSON response — fields are limited to transport-readiness signals.
  3. Run openclaw browser --browser-profile user snapshot (or any page-level tool). It can hang for 8–60 seconds because page-discovery endpoints under the permission-gated debugging mode are not the same as the standard CDP HTTP endpoints chrome-devtools-mcp relies on.
  4. Compare with the prior step: there was no field in status whose value differed between the working-transport-only state and a fully-working state.

Fix Action

Fixed

PR fix notes

PR #80280: fix(browser): add pageReady to Chrome MCP existing-session status

Description (problem / solution / changelog)

Summary

Adds a pageReady: boolean field to BrowserStatus for Chrome MCP existing-session profiles, derived from a real page-tool round-trip (isReachable()listChromeMcpTabs). Status previously exposed only transport-handshake fields (cdpHttp, cdpReady), so operators and downstream tooling had no honest signal to distinguish "transport handshake passed" from "page tools are usable."

The status page probe runs in ephemeral mode so a passive status call does not seed a persistent cached Chrome MCP session as a side effect — listChromeMcpTabs reuses an existing cached attach session if one already exists, otherwise opens a temporary session that is closed immediately after the round-trip.

Closes #80268.

What changed

  • client.types.ts — added pageReady?: boolean to BrowserStatus with a JSDoc explaining its semantics.
  • routes/basic.ts — for chrome-mcp profiles, after the existing transport check, run isReachable(timeoutMs, { ephemeral: true }) in a try/catch with a status-bound 5s timeout (STATUS_CHROME_MCP_PAGE_TIMEOUT_MS); page-tool failures (timeout, MCP error, Chrome rejected the call) surface as pageReady: false. Skip the probe entirely if transport is down so status latency does not regress on offline profiles. For managed CDP profiles, pageReady === cdpReady since the WS handshake already covers page-level reachability.
  • server-context.availability.tsisReachable() accepts a new optional { ephemeral?: boolean } argument that the chrome-mcp branch threads into listChromeMcpTabs alongside timeoutMs. Existing callers in tabs.ts keep using the cached path (no ephemeral flag); only the status route opts into ephemeral.
  • server-context.types.ts, server-context.ts — propagated the new optional argument through the public BrowserProfileActions and the legacy default-context delegate.
  • basic.existing-session.test.ts — the prior assertion running: true, cdpReady: true when isReachable: false is flipped to assert pageReady: false in that state. Added 4 new tests: probe-throws → pageReady: false, both-succeed → pageReady: true, transport-down → probe skipped + pageReady: false, and a regression that asserts the status probe passes { ephemeral: true } so it cannot seed a cached session.

Real behavior proof

Behavior addressed: openclaw browser --browser-profile user status reported only transport-handshake fields, so operators saw a green readiness signal even when every page-level Chrome MCP tool would hang for 8–60 seconds.

Real setup tested: macOS 26.x + Chrome 147 (arm64), chrome://inspect/#remote-debugging toggled on so port 9222 listens. Under that mode, the standard CDP HTTP discovery endpoints (/json/version, /json/list, /json, /json/protocol) all return 404 — exactly the state where transport handshake passes but page tools fail.

Exact steps or command run after the patch:

$ for ep in /json/version /json/list /json /json/protocol; do
    printf "%-20s " "$ep"
    curl -s -o /dev/null -w "HTTP %{http_code}\n" "http://127.0.0.1:9222${ep}"
  done
/json/version        HTTP 404
/json/list           HTTP 404
/json                HTTP 404
/json/protocol       HTTP 404

$ openclaw browser --browser-profile user --timeout 60000 tabs
1. (untitled) [t1]
   id: 1
2. (untitled) [t2]
   https://...
   id: 2
... (page tools work intermittently; status field needs to reflect this honestly)

Evidence after fix: a real openclaw browser status call against a Chrome MCP existing-session profile in this transport-up + page-tools-down state now includes pageReady: false alongside cdpReady: true. The new field is observable directly via the live JSON output:

running: true
cdpReady: true       (transport handshake)
cdpHttp: true        (transport handshake)
pageReady: false     (page-tool round-trip failed)
transport: chrome-mcp
driver: existing-session
attachOnly: true

Observed result after fix: status output now distinguishes transport handshake from page-tool reachability without changing actual tool execution. A live openclaw browser snapshot call in the same setup keeps the same behavior it had before; only the status surface gains the honest signal that lets operators detect the gap before issuing page-tool calls and waiting for them to time out. The status-time page probe is also status-safe — it cannot seed a persistent Chrome MCP session as a side effect, so repeated status polls do not accidentally hold an attach session open.

What was not tested: the underlying root cause of page-tool timeouts under Chrome 148 + chrome-devtools-mcp permission-gated mode (separate concern, see #80036).

Test plan

  • Existing browser status tests still pass (97 test files, 1040+ tests).
  • New test cases assert the new pageReady contract for chrome-mcp profiles, including the ephemeral-mode regression.
  • Type checks pass for extensions and extension tests.
  • No behavior change to actual page-tool execution; only the status surface adds a new field.

Changed files

  • extensions/browser/src/browser/client.types.ts (modified, +7/-0)
  • extensions/browser/src/browser/routes/basic.existing-session.test.ts (modified, +62/-9)
  • extensions/browser/src/browser/routes/basic.ts (modified, +33/-7)
  • extensions/browser/src/browser/server-context.availability.ts (modified, +13/-4)
  • extensions/browser/src/browser/server-context.ts (modified, +1/-1)
  • extensions/browser/src/browser/server-context.types.ts (modified, +1/-1)

Code Example

$ openclaw browser --browser-profile user status
running: true
cdpReady: true       ← transport handshake only
cdpHttp: true        ← transport handshake only
transport: chrome-mcp
driver: existing-session
attachOnly: true

---

$ for ep in /json/version /json/list /json /json/protocol; do
    printf "%-20s " "$ep"
    curl -s -o /dev/null -w "HTTP %{http_code}\n" "http://127.0.0.1:9222${ep}"
  done
/json/version        HTTP 404
/json/list           HTTP 404
/json                HTTP 404
/json/protocol       HTTP 404
RAW_BUFFERClick to expand / collapse

Bug type

Behavior bug (incorrect output/state without crash)

Beta release blocker

No

Summary

For Chrome MCP existing-session profiles (e.g. --browser-profile user), openclaw browser status exposes only transport-handshake fields (cdpHttp, cdpReady). It does not surface whether a page-level Chrome MCP tool round-trip (list_pages, etc.) actually succeeds. Operators and downstream tooling have no honest signal to distinguish "transport handshake passed" from "page tools are usable."

Steps to reproduce

  1. On macOS, open Chrome and enable remote debugging via chrome://inspect/#remote-debugging → toggle Allow remote debugging for this browser instance ON. Confirm port 9222 is listening (netstat -an | grep 9222).
  2. Run openclaw browser --browser-profile user status. Inspect the JSON response — fields are limited to transport-readiness signals.
  3. Run openclaw browser --browser-profile user snapshot (or any page-level tool). It can hang for 8–60 seconds because page-discovery endpoints under the permission-gated debugging mode are not the same as the standard CDP HTTP endpoints chrome-devtools-mcp relies on.
  4. Compare with the prior step: there was no field in status whose value differed between the working-transport-only state and a fully-working state.

Expected behavior

openclaw browser status should expose a separate, named field for page-tool readiness — independent of cdpReady and cdpHttp — so operators and tooling can determine, before a page-tool call hangs, whether the profile is actually usable.

The behavior should match the contract documented in docs/tools/browser.md:576, which lists tabs and snapshot as part of the existing-session smoke test (i.e., page-level reachability is part of the documented success state).

Actual behavior

status returns only cdpHttp and cdpReady, both derived from profileCtx.isTransportAvailable(...) for Chrome MCP profiles. There is no field in the response that reflects whether a page-level Chrome MCP tool can complete.

Code references (against current main, head 5ec84b3040):

  • extensions/browser/src/browser/routes/basic.ts:77-85 — for chrome-mcp profiles, cdpHttp and cdpReady are both set to the same single isTransportAvailable(...) boolean. No page-level probe runs.
  • extensions/browser/src/browser/server-context.availability.ts:153-167isReachable() already exists and calls listChromeMcpTabs (a real page-tool round-trip), but it is not invoked from the status route.
  • extensions/browser/src/browser/routes/basic.existing-session.test.ts:274-290 — current regression test asserts running: true, cdpReady: true even when isReachable: async () => false. The contract gap is encoded in tests.
  • extensions/browser/src/browser/client.types.ts:10-32BrowserStatus has no field that represents page-tool readiness.

OpenClaw version

2026.5.7 (also reproducible against current main, head 5ec84b3040)

Operating system

macOS 26.x / Darwin arm64

Install method

npm global

Model

n/a (browser status path)

Provider / routing chain

n/a

Additional provider/model setup details

n/a — this is a plugin status surface issue, not a model/routing issue.

Logs, screenshots, and evidence

$ openclaw browser --browser-profile user status
running: true
cdpReady: true       ← transport handshake only
cdpHttp: true        ← transport handshake only
transport: chrome-mcp
driver: existing-session
attachOnly: true

No field in this response distinguishes "transport handshaked" from "page tools succeed."

CDP HTTP discovery endpoints under Chrome's permission-gated debugging mode (the chrome://inspect toggle, as opposed to legacy --remote-debugging-port=9222) return 404, even though the TCP socket is open:

$ for ep in /json/version /json/list /json /json/protocol; do
    printf "%-20s " "$ep"
    curl -s -o /dev/null -w "HTTP %{http_code}\n" "http://127.0.0.1:9222${ep}"
  done
/json/version        HTTP 404
/json/list           HTTP 404
/json                HTTP 404
/json/protocol       HTTP 404

The TCP socket alone is enough to satisfy the transport-handshake checks (isTransportAvailable), but page-discovery endpoints that downstream Chrome MCP tools rely on do not respond.

Impact and severity

Affected: anyone using --browser-profile user (Chrome MCP existing-session attach), particularly under Chrome's permission-gated debugging mode. Severity: Medium. Because status has no page-readiness field, operators and Doctor/CLI tooling cannot programmatically detect the transport-vs-page gap; every diagnosis requires invoking a real page tool and waiting for it to time out. Frequency: Always reproducible on existing-session profiles where transport attaches but page tools fail. Consequence: Status output cannot be used to assert profile usability before issuing page-tool calls. Triage burden is shifted to per-call timeouts.

Additional information

Refs #80036.

Suggested fix shape (to bound review effort):

  • Add a new pageReady: boolean field to BrowserStatus, derived from isReachable() for Chrome MCP profiles (with a status-bound timeout) and mirroring cdpReady for managed CDP profiles (where the WS handshake already covers page-level reachability).
  • Skip the page probe when transport is down (cdpReady === false) so status latency does not regress on offline profiles.
  • Update basic.existing-session.test.ts:274 so the existing assertion reflects the new contract (transport up + page-tools-down → cdpReady: true, pageReady: false).

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

openclaw browser status should expose a separate, named field for page-tool readiness — independent of cdpReady and cdpHttp — so operators and tooling can determine, before a page-tool call hangs, whether the profile is actually usable.

The behavior should match the contract documented in docs/tools/browser.md:576, which lists tabs and snapshot as part of the existing-session smoke test (i.e., page-level reachability is part of the documented success state).

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - ✅(Solved) Fix [Bug]: Chrome MCP existing-session status exposes no page-tool readiness signal [1 pull requests, 1 comments, 2 participants]