Repository navigation
Description
Problem
In background Firefox, after the page moves focus from one field to another, macOS accessibility still reports the earlier field as focused. type_text's read-back then snapshots and polls the wrong element.
The text lands correctly in the newly focused field, but the call can never confirm:
- Literal requests answer
valueMismatch, with an excerpt and the lengths of the other field. - Concealed requests answer
concealedMismatch. - Password fields: macOS engine: type_text into a password field confirms by character-count delta, emitting no count (808's rule) #414's length confirmation can't reach them either, because the element read is the stale plain field, not the password input.
Measured in #414's Firefox identity diagnostic (run 44342395472, Firefox 160 on hosted macOS, main 517ab54 and #414's head):
- The production snapshot's element was the earlier setup field in 12/12 trials: AXTextField, no subrole. It was never the password input or an ancestor or descendant of it.
- The DOM showed the password exact and the setup field unchanged, 12/12.
- No password value or mask appeared in any reply.
- Literal excerpts matched the setup field only.
This is wrong-target, not a leak: the excerpt is of a field the agent could observe anyway. It is never a wrong success either, because the stale field doesn't change, so it never equals the expected value. But it means type_text into a field that was focused from the page never confirms in background Firefox. The #405 qualification also saw Firefox's AX focus on the web area for its focused-selection path. Related: agent-cursor.md already says background Firefox doesn't report its caret moving.
What to find out
- Which focus sources update. Which of Firefox's AX focus sources (the application's AXFocusedUIElement, the window's, the web area's, AXFocused on the elements) update for a page-driven focus change in the background, and which stay stale?
- Detecting staleness. Can the read-back detect the stale case before input, for example the claimed element reading AXFocused false, or another element reading AXFocused true? Then refuse it (
noFocusedElementorfieldChanged) instead of reading another field. - Finding the real field. If a reliable source exists (a walk for AXFocused true, or Gecko's own text-marker or caret attributes), use it, under macOS engine: background Safari on a large page can't find the focused field for type_text's read-back (text-marker route) #395's and macOS engine: observation never reads a secure field's value, length or selection (protection is the AX provider's today) #405's privacy rules.
Check
In background Firefox, after the page moves focus between two fields, type_text's read-back targets the newly focused field. It confirms 20/20 for plain fields, and gives #414's length confirmation for password fields. No reply carries another field's excerpt.
Spawned by #414 (design ruling 1ea561bc:839: every declared limit gets its own ticket).
Activity
SSFSKIM commentedon Nov 18, 2026
Second Firefox shape, from #414's qualification: a page whose only field is the password input, focused by the page before Firefox went to the background (13/13 setup-valid, Firefox 160 hosted, main 517ab54 and #414 cbce12e). Both heads delivered exactly, including non-BMP text, but answered notTextField: Firefox's AX reports the web area, not the input, as focused. So in background Firefox, type_text's read-back never reaches a password field, whether a field was focused before it (stale focus, above) or not (web area focus). Nothing private appeared in any reply.
Probe 420: admit a non-secret refusal's constant zero counters on bot…