Skip to content

[Bug]: Keyboard is taken over when using Orca browser skill #8139

Closed

Description

@ryanmargono

Operating system

macOS

Orca version

No response

Details

When using orca browser skill, if the agent is trying to type something, it takes over my keyboard so I cant type and multi task. My keyboard ends up interfering with its task as well (ofc as its vice versa)

Activity

  1. added theissue type on Jul 12, 2026
  2. nwparker commented on Jul 27, 2026

    @nwparker
    Contributor

    Attempted repro — cannot_repro

    Tried

    1. Reviewed computer-use / browser skill keyboard injection paths at a high level.
    2. Could not run a full agent browser-skill session that synthesizes key events while measuring host keyboard steal without hijacking the interactive desktop of this machine.

    Result

    Needs an isolated computer-use automation that asserts keyboard focus ownership during agent typing. Not reproduced here.

  3. added
    pending_reproRepro attempted; still pending conclusive reproduction
    on Jul 27, 2026
  4. grboy6770 commented on Jul 27, 2026

    @grboy6770
    Contributor

    Reproduced — the trigger is click, not typing

    Re: the cannot_repro above. I think the repro failed because the search was aimed at the typing path. In my measurements typing is not the trigger — synthetic mouse presses are.

    Input.dispatchMouseEvent with mousePressed makes Chromium hand native focus to the guest view that received the press, so an agent clicking in a background tab pulls the caret out of whatever pane the user is typing in.

    Method (no interactive-desktop hijack needed)

    Drive a scratch tab with orca CLI on a loop while a human types continuously in a terminal pane in the same window. Each segment writes execution evidence into the page (a click counter and the final input value) so a silently-skipped command can't be mistaken for a clean run.

    Measured on 1.4.158 / macOS, against a local file:// page — no app under test required:

    Command Commands issued Caret in the user's pane
    snapshot / get / is / network 32 held
    eval (DOM .click() + value set) 224 @ 1.5/s held
    fill 37 + 38 held
    click 39 + 38 lost

    Order-reversed crossover

    Running one command type per segment and then reversing the order rules out a warm-up or time-of-day confound:

    Run Order click segment fill segment
    1 click → fill caret lost caret held
    2 fill → click caret lost caret held

    Same result per command regardless of position.

    Why the other paths are fine

    The two neighbouring input paths already compensate, which is why typing looked innocent:

    • Input.insertText replays the pending DOM.focus (fix(browser): restore programmatic focus for CDP text insertion #7041)
    • Runtime.evaluate is deliberately excluded from auto-focus — the comment in cdp-ws-proxy.ts calls out this exact failure mode ("focusing on every eval steals the user's foreground window while background automation is running")

    Input.dispatchMouseEvent had no equivalent.

    Fix

    Opened #10875, which captures the focused host WebContents around the synthetic mouse dispatch and hands focus back. Applied to click, drag and check. DOM focus still follows the click, so click → fill flows are unaffected.

    Caveat on scope

    I only have evidence for the mouse path, so I marked that PR Related to rather than Fixes this issue. The original report mentions typing; type / inserttext go through Input.insertText, which still calls webContents.focus() by design and which I did not measure. If the reporter's symptom persists after #10875 with typing alone, that path is worth a separate look.

  5. AmethystLiang commented on Jul 27, 2026

    @AmethystLiang
    Contributor

    Thanks for reporting @ryanmargono and @grboy6770 for the fix PR! Will try to land it soon

  6. paul-vd commented on Sep 10, 2026

    @paul-vd

    Same on Orca 1.4.199, macOS 26.6, Claude Code agent.

    While one worktree's session drives the embedded browser with the orca CLI, typing a prompt in a different session's terminal is unusable: the prompt input loses focus on every browser action, so you have to click back into the input and continue, then lose it again a moment later. Effectively nothing else can be done in Orca while any session is using the browser. Likely the same root cause as #19297 and the keystroke side of #12912.

  7. nwparker commented on Oct 15, 2026

    @nwparker
    Contributor

    Fixed by #28452, #28453 and #28454 (tracked in #20595), now on main: agent type, keypress, fill and click reach the targeted page and no longer land in, or take focus from, whatever you're typing in. Details and remaining limits are in #20595. Please reopen with your OS and the exact command if you still see it on the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingos:macosIssues affecting macOSpending_reproRepro attempted; still pending conclusive reproduction

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions