githubnext/ace2Public

Ace: a collaborative coding environment on the team's own machines

fix(desktop): verify focus before pressing editable fields #120

Mergediamnbutlermerged 4 commits intomainfromrefs/pull/120/head
  1. IA

    Single element clicks on editable Accessibility text fields now use verified focus before `AXPress`. WebKit can accept `AXPress` on a contenteditable without focusing it, leaving subsequent keyboard operations without a usable receiver (#106, part of #8).

    Native focus writes run off MainActor while retaining the operation lane until completion, so Ace can service its own Accessibility request. Ambiguous write failures stay indeterminate, with no second input path. Exact process/window/element checks and normal button presses are preserved. Coordinate occlusion and paste/type behavior in #106 remain separate work.

    Validated on frozen `9374d8001211968aae8f12b03c7e598e093578b0`:

    - Types, formatting/lint, independent source review, signed normal development build, strict app/client/launcher signatures, and GitHub CI pass. Uses the shared development identity and existing grants from #123. - A real signed WKWebView fixture verified focus once, already-focused no-op, ordinary button activation, and pre-dispatch cancellation. Its text and key/input/paste/submit counters stayed unchanged. - A real OpenAI channel run performed inspect → one element focus → inspect. Exact tool results/images and usage survived an actual worker exit/reopen with no new native calls, provider usage or fixture input. - The actual isolated Ace composer changed from `isFocused=false` to `true` with a confirmed Accessibility focus write. Its default draft and empty channel history/usage remained unchanged. The saved AX values were independently checked after correcting a helper assertion's property path; no input was repeated.

    The stale-window check retained its original conservative **unknown** result after a verified move; fixture counters confirmed no input and no retry occurred. Source inspection locates this unchanged classification before the new focus path. In-flight cancellation is not claimed. First native inspection of fresh WebKit processes still exposed only chrome nodes; one later read-only inspection exposed the field (#64), so this PR does not claim to fix initial AX availability.

    Cleanup is complete: both disposable fixture processes, all model/self-check workers, both temporary channels/projects, and the normal development runner, GUI and source host are closed or removed; its listener is gone. The separate #106 point-click observation remains outside this PR.

    ### Built in Ace

    Nate explicitly allowed direct tools for this #8 pass. Codex shell/file tools and review agents implemented, inspected and built the change; GitHub CLI updates the PR. Validation used the actual signed Ace bridge, normal isolated development runner and real Ace channel/provider. Codex computer use opened only the disposable self-check channel; the focus under test was sent through Ace's native tool. The capability gap is #106; external harness support remains #9. No installed development app or Canary data was changed.

  2. iamnbutlerreferenced this in Focus and paste into WebKit composers with native desktop tools #106last month on GitHub

  3. iamnbutlerreferenced this in [Meta] Complete native computer use in Ace #8last month on GitHub

  4. iamnbutlerreferenced this in fix(desktop): resolve containing windows for pointer input #131last month on GitHub

  5. iamnbutlerready-for-reviewlast month on GitHub

  6. iamnbutlermerged 62182fc17072last month on GitHub

  7. iamnbutlerclosedlast month on GitHub

  8. iamnbutlerreferenced this in feat(desktop): add exact-target normal application quit #132last month on GitHub