You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Spike: which timeout governs locator and CDP actions in the vendor browser API (3 s deadline seen regardless of js timeout) #25
During the dogfood run several locator actions reported a deadline near three seconds even when a longer locator timeout had been set earlier in the session, and increasing the outer js call's timeout did not raise the locator/CDP action deadline. Which budget actually applies to locator actions and Runtime.evaluate in the vendor browser API, and how is it set?
Method
Read the vendor browser API in the readable source (create_browser_api.js and the locator helpers) for the default action timeout and any per-call override; then a minimal live reproduction against an owned slow page (a local HTTP server that delays an element's appearance) through cua serve: locator wait with default, with a per-call timeout, with a long outer js timeout. Record the observed deadlines.
Deliverable
Findings comment: the budget model, the correct way to extend it, and the host-note sentence for #23. If a vendor default cannot be raised from the API, say so.
Spike findings: the locator/CDP deadline is a vendor hard cap of 3 s
Answer. Every locator action, selector read, playwright.evaluate, waitForLoadState and waitForURL in the pinned vendor browser service (@oai/browser-desktop 0.1.1, release 26.928.40906) is bounded by the service-side deadline min(max(0, timeout_ms ?? 3000), max || 3000). Those commands pass no max, so 3000 ms is a ceiling, not a default: a per-call timeoutMs can shorten it but never raise it. There is no session-level setter, and the js tool's timeout_ms is not forwarded to browser commands. The vendor default cannot be raised from the API.
Budget model (installed runtime, ~/Library/Application Support/cua/runtimes/26.928.40906-darwin-arm64/cua_node/lib/node_modules/@oai/browser-desktop/scripts/, minified; readable line in brackets is ~/codex-app-src/readable/chatgpt-26.928.40906/cua_node/@oai/browser-desktop/scripts/)
bounds the whole cell only; on expiry the reply is js execution timed out; kernel reset, rerun your request and REPL globals (tab handles) are lost
measured below
There is no setDefaultTimeout or equivalent in either the client or the service. The vendor option is timeoutMs; a Playwright-style {timeout: N} is ignored, though the cap means it would not help anyway. So the dogfood observations follow directly: "a longer locator timeout set earlier in the session" cannot exist, a longer outer js timeout changes nothing below the cell, and the confirmation click's Runtime.evaluate timeout matches the 3 s action deadline on that click's internal CDP evaluate. The nested-frame press timeout may be the same cap; that was not reproduced here.
Correct way to wait longer from a js cell
Loop short waits inside the cell up to your own deadline, and give the js call a timeout_ms above that deadline plus a margin. Keep the margin generous, because an outer timeout resets the kernel and loses the tab handle:
For evaluate, the page script itself must finish within 3 s. Poll from the cell instead of awaiting a long promise in the page.
Measured (2026-10-05, live, cua serve with CUA_SHIM_SURFACES=computer,browser, default CUA_HOME, profile personal ready)
The setup was one owned tab on a loopback page whose #late button appears N ms after load. Each test was a fresh goto. The timing is around the action itself.
js execution timed out; kernel reset, rerun your request
wall 3018
Cleanup. The created tab was closed and confirmed absent from listTabs. There was 1 elicitation, the own-origin access, accepted for the session; no other elicitations. end_task returned ended and the server exited 0. No other tab was touched.
Incidental. The first browser command after getBrowser once failed after about 24 s with Unable to load browser request-header policy. Retry the browser command.; the next command worked. An earlier attempt from a sandboxed shell failed createBrowserTab after 19 s with nodeRepl.fetch request failed. The service reads this policy before sending each session request to the extension (sendSessionRequest, readable 68061), so no tab should have been created, but that was not confirmed by listing.
- Browser locator actions, waits and playwright.evaluate stop at 3 s whatever timeoutMs or the js timeout_ms say (timeoutMs can only shorten it); to wait longer, loop short waits in the cell up to your own deadline and give the js call a timeout_ms above it.
[board] done: Findings posted: 3 s is a fixed vendor cap (browser-service.mjs helper, timeout_ms ?? 3000 capped at 3000); only shortening possible; loop short waits in the cell. Host-note sentence handed to #23.
Activity
SSFSKIM commentedon Oct 5, 2026
[board] in-progress: Spike started: static read of the installed vendor browser API, then a minimal owned live probe through cua serve
SSFSKIM commentedon Oct 5, 2026
Spike findings: the locator/CDP deadline is a vendor hard cap of 3 s
Answer. Every locator action, selector read,
playwright.evaluate,waitForLoadStateandwaitForURLin the pinned vendor browser service (@oai/browser-desktop0.1.1, release 26.928.40906) is bounded by the service-side deadlinemin(max(0, timeout_ms ?? 3000), max || 3000). Those commands pass nomax, so 3000 ms is a ceiling, not a default: a per-calltimeoutMscan shorten it but never raise it. There is no session-level setter, and thejstool'stimeout_msis not forwarded to browser commands. The vendor default cannot be raised from the API.Budget model (installed runtime,
~/Library/Application Support/cua/runtimes/26.928.40906-darwin-arm64/cua_node/lib/node_modules/@oai/browser-desktop/scripts/, minified; readable line in brackets is~/codex-app-src/readable/chatgpt-26.928.40906/cua_node/@oai/browser-desktop/scripts/)qetimeout_ms ?? 3000, clamped tomax || 3000browser-service.mjs:6432[18546]click/dblclick(clickLocator),fill/type/press(focusLocator,prepareLocatorFill, pressDate.now()+qe(t)),check/selectOption,waitFor,textContent/innerText/getAttribute/count(selector resolution and evaluate helpers):6511press [43844],:6681waitFor [49968],:6700selector resolution + "Playwright selector deadline exceeded" [54705, 54861],:6718/:6741selector evaluate [55077, 55128],:6755click/focus [55214, 55258]tab.playwright.evaluate(read-only scope):7119[56931]waitForLoadState,waitForURL:6681[50195, 50237]pressSequentially:6681($O=5e3) [49778]downloadMedia,waitForEvent("download"/"filechooser"):6681(max:12e4) [49625, 50018, 50036]capabilities.get("cdp").send(..., {timeoutMs}):6686[54223]; needs full CDP enabled and an extension/IAB tabRuntime.evaluate, input dispatch):6674af()[48772]timeoutMstimeout_ms(clamped above) and as transportclient_timeout_ms; the service never reads the latterbrowser-client.mjs:7locator methods,:9FunctionAgentTransport.send[7246-7440, 10428]jstimeout_ms(default 30 s;docs/evidence/m3-mcp-lifecycle.md:70)js execution timed out; kernel reset, rerun your requestand REPL globals (tab handles) are lostThere is no
setDefaultTimeoutor equivalent in either the client or the service. The vendor option istimeoutMs; a Playwright-style{timeout: N}is ignored, though the cap means it would not help anyway. So the dogfood observations follow directly: "a longer locator timeout set earlier in the session" cannot exist, a longer outerjstimeout changes nothing below the cell, and the confirmation click'sRuntime.evaluatetimeout matches the 3 s action deadline on that click's internal CDP evaluate. The nested-framepresstimeout may be the same cap; that was not reproduced here.Correct way to wait longer from a
jscellLoop short waits inside the cell up to your own deadline, and give the
jscall atimeout_msabove that deadline plus a margin. Keep the margin generous, because an outer timeout resets the kernel and loses the tab handle:For
evaluate, the page script itself must finish within 3 s. Poll from the cell instead of awaiting a long promise in the page.Measured (2026-10-05, live,
cua servewithCUA_SHIM_SURFACES=computer,browser, defaultCUA_HOME, profilepersonalready)The setup was one owned tab on a loopback page whose
#latebutton appears N ms after load. Each test was a freshgoto. The timing is around the action itself.waitFor({state:"visible"})waitFor({..., timeoutMs: 1000})waitFor({..., timeoutMs: 20000})jstimeout_ms: 90000Timed out after 3000ms waiting for selector #latewaitFor({..., timeout: 20000})(Playwright spelling)click()click({timeoutMs: 20000})textContent({timeoutMs: 20000})press("Enter", {timeoutMs: 20000})waitFor({..., timeoutMs: 20000})playwright.evaluate(async 6 s, undefined, {timeoutMs: 20000})Timed out after 2997ms waiting for CDP command Runtime.evaluate.playwright.evaluate(async 1 s)jstimeout_ms: 3000js execution timed out; kernel reset, rerun your requestCleanup. The created tab was closed and confirmed absent from
listTabs. There was 1 elicitation, the own-origin access, accepted for the session; no other elicitations.end_taskreturnedendedand the server exited 0. No other tab was touched.Incidental. The first browser command after
getBrowseronce failed after about 24 s withUnable to load browser request-header policy. Retry the browser command.; the next command worked. An earlier attempt from a sandboxed shell failedcreateBrowserTabafter 19 s withnodeRepl.fetch request failed. The service reads this policy before sending each session request to the extension (sendSessionRequest, readable 68061), so no tab should have been created, but that was not confirmed by listing.Host-note sentence for #23
- Browser locator actions, waits and playwright.evaluate stop at 3 s whatever timeoutMs or the js timeout_ms say (timeoutMs can only shorten it); to wait longer, loop short waits in the cell up to your own deadline and give the js call a timeout_ms above it.SSFSKIM commentedon Oct 5, 2026
[board] done: Findings posted: 3 s is a fixed vendor cap (browser-service.mjs helper, timeout_ms ?? 3000 capped at 3000); only shortening possible; loop short waits in the cell. Host-note sentence handed to #23.
State the fixed 3 s browser action cap in the host notes (spike #25)