Commit 3bf3ff1
authored
* diag: instrument Linux CI to gather evidence for #1935 input/a11y defects
Temporary — adds a diagnostic step that dumps raw AT-SPI interfaces/actions
for gnome-calculator's digit buttons, tests a raw xdotool click at a
button's own rect (bypassing our promotion logic), and isolates the typed
'=' character in several configurations. Will be removed once the real
fixes land.
* diag: harden diagnostic step against bash -e and AT-SPI registration races
The prior version crashed 7s in: GH Actions runs steps under bash -e, and
an unguarded python3 heredoc threw (iterating a dict instead of a list
when the app wasn't found yet), aborting the rest of the script silently
under continue-on-error. Guards every fallible command, and replaces the
fixed 2s sleep with inspect.py's own poll-until-found loop.
* diag: test WINDOW coordtype and static Text.get_text call (round 3)
Round 2 proved Component.get_extents(SCREEN) returns (0,0) for every
non-toplevel widget (real click miss confirmed on-screen), and
Text.get_text() throws — a documented PyGObject binding collision with
the deprecated 1-arg Accessible.get_text(). This narrows to the two
candidate fixes before writing them: does CoordType.WINDOW give usable
relative offsets, and does Atspi.Text.get_text(accessible, ...) (static
call) return the real typed text.
* fix(linux): resolve click-miss, dropped '=', and GTK4 text exposure defects
Three defects surfaced by CI on #1935 (Linux Smoke lane), all confirmed
live via instrumented CI runs before being fixed here:
1. Click misses its target: Component.get_extents(Atspi.CoordType.SCREEN)
returns (0, 0) as the origin for every non-toplevel widget under this
GTK4 build — confirmed by a raw click at the computed rect center
landing on the window's own header-bar button instead of the intended
digit button. CoordType.WINDOW gives correct, distinct per-widget
offsets, so get_rect() now computes screen-absolute rects as that
offset plus the enclosing top-level frame's own (correct) screen
origin, threaded through traverse_node() alongside the existing
window-title tracking. Complementary hardening: role "label" is now
excluded from `hittable`, since GTK4 wraps every button's caption in a
same-rect "label" child, and the shared cross-platform promotion logic
in interaction-targeting.ts would otherwise retarget a click from the
button onto that non-interactive label.
2. Typed '=' never arrives: a single isolated synthetic keystroke sent
right after a focus change is unreliably delivered — confirmed live,
both `xdotool type -- "="` and `xdotool key equal` sent alone produced
no character at all, while multi-character bursts always landed in
full. typeLinux and sendKey now wait a short settle margin before
dispatching to xdotool/ydotool, absorbing the race regardless of which
action last changed focus.
3. GTK4 apps expose no editable text: accessible.get_text_iface().get_text()
throws "Atspi.Accessible.get_text() takes exactly 1 argument (3 given)"
— a documented PyGObject binding collision between Text.get_text and
the deprecated 1-argument Accessible.get_text, silently swallowed as
"no text" by the broad exception handler. get_text_value() now calls
the unbound Atspi.Text.get_text(accessible, ...) form, which correctly
returns the real content.
The Linux smoke replay is restored to exercise all three fixes together
(click a resolved digit button, type a full calculation including the
'=' keystroke, wait on the computed result through the tree) instead of
staying at the weakened, contract-tier assertions the defects had forced.
The coverage manifest promotes click and type from command-contract to
live accordingly.
* fix(linux): drop unproven keyboard-settle and hittable changes per review
Addresses thymikee's review on #1949 (both points correct):
P1: the keyboard settle (typeLinux/sendKey) was unjustified. The cited
diagnostic evidence for a dropped '=' actually shows the opposite —
"100+55=" and "5=5" both computed correctly with zero settle, proving
'=' was delivered in every multi-character burst tested. Sending '='
alone to an empty entry showing a blank display is normal calculator
semantics (nothing to evaluate), not a lost keystroke. The likelier
explanation for the original "100+55" screenshot (run 32487868346) is
that its attempt-3 hit the already-fixed mousemove --sync hang, not an
independent keyboard-dispatch defect. Reverted; no keyboard-dispatch
change was needed.
P2: the `role_name != "label"` hittable narrowing was extra surface
beyond what the click-miss fix required. The corrected AT-SPI coordinates
alone fix the observed miss — the button and its same-rect label child
resolve to nearly identical centers, so descendant promotion still lands
inside the button either way, and the replay can't distinguish which
node it actually targeted. Reverted; only the coordinate fix remains.
1 parent 1f80c92 commit 3bf3ff1
4 files changed
Lines changed: 92 additions & 36 deletions
File tree
- linux
- test/integration
- linux-e2e
- replays/linux
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
25 | | - | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
26 | 32 | | |
27 | 33 | | |
28 | 34 | | |
29 | 35 | | |
30 | 36 | | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
31 | 59 | | |
32 | 60 | | |
33 | 61 | | |
34 | 62 | | |
| 63 | + | |
35 | 64 | | |
36 | | - | |
37 | | - | |
| 65 | + | |
| 66 | + | |
38 | 67 | | |
39 | 68 | | |
40 | 69 | | |
| |||
43 | 72 | | |
44 | 73 | | |
45 | 74 | | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
46 | 85 | | |
47 | 86 | | |
48 | 87 | | |
49 | 88 | | |
50 | | - | |
| 89 | + | |
51 | 90 | | |
52 | 91 | | |
53 | | - | |
| 92 | + | |
54 | 93 | | |
55 | 94 | | |
56 | 95 | | |
| |||
76 | 115 | | |
77 | 116 | | |
78 | 117 | | |
79 | | - | |
| 118 | + | |
80 | 119 | | |
81 | 120 | | |
82 | 121 | | |
| |||
96 | 135 | | |
97 | 136 | | |
98 | 137 | | |
99 | | - | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
100 | 145 | | |
101 | 146 | | |
102 | 147 | | |
| |||
110 | 155 | | |
111 | 156 | | |
112 | 157 | | |
113 | | - | |
| 158 | + | |
114 | 159 | | |
115 | 160 | | |
116 | 161 | | |
| |||
147 | 192 | | |
148 | 193 | | |
149 | 194 | | |
150 | | - | |
| 195 | + | |
151 | 196 | | |
152 | 197 | | |
153 | 198 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
160 | 160 | | |
161 | 161 | | |
162 | 162 | | |
163 | | - | |
164 | | - | |
165 | | - | |
166 | | - | |
167 | | - | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
168 | 168 | | |
169 | 169 | | |
170 | 170 | | |
| |||
181 | 181 | | |
182 | 182 | | |
183 | 183 | | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
188 | | - | |
189 | | - | |
190 | | - | |
191 | | - | |
192 | | - | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
193 | 189 | | |
194 | 190 | | |
195 | 191 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
19 | 26 | | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
26 | 35 | | |
27 | | - | |
28 | | - | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
44 | | - | |
45 | | - | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
46 | 47 | | |
47 | | - | |
| 48 | + | |
48 | 49 | | |
49 | 50 | | |
50 | 51 | | |
| |||
61 | 62 | | |
62 | 63 | | |
63 | 64 | | |
64 | | - | |
| 65 | + | |
65 | 66 | | |
66 | 67 | | |
67 | 68 | | |
| |||
0 commit comments