After the selection-replacement autocorrect on the phone, Gboard's local text was out of sync with ours and it re-sent the same empty fix-up commit in an endless loop (~one per 150 ms, each drift-snapped to the caret and applied as a no-op). The file was never damaged, but the IME never converged because it kept 'fixing' text that did not exist in its own model. The app cannot see the IME's model; the only recovery the IME contract offers is a restartInput, which makes it re-fetch the real text and selection around the caret. Arm that recovery automatically: three consecutive anomalous commits (drift-snapped, or empty text) set IMEForceResync, and the next frame ships the snippet trimmed by one rune, which changes the pushed text and forces the restart. The streak resets on any normal commit, so isolated anomalies never trigger it, and the resync is one-shot. TestRealFile_IMEForceResync pins the arm/reset/consume cycle. |
||
|---|---|---|
| .. | ||
| icons | ||
| caret_point_test.go | ||
| element.go | ||
| layout.go | ||
| pinch_test.go | ||
| pinch_tracker.go | ||
| real_draw_probe_test.go | ||
| render.go | ||
| reveal_focus_drain_test.go | ||
| tag_identity_test.go | ||
| unit.go | ||