Repository navigation
test(linux): wait for AT-SPI rows before toggling (settings-poll flicker) - #47
Merged
Merged
Conversation
…ker) The toggle helpers read their target from the panel-derived dict with a bare keywords()[text] / regexes()[pattern]. A just-added row can briefly vanish from the panel when the settings-poll reload rebuilds it, so that read races the rebuild and dies with KeyError — this flaked on main (build-linux x64 leg, run 36803538442: test_keyword_case_button and test_regex_toggle_and_delete both failed this way; same commit passed on the PR run and on arm64). Add _keyword_state/_regex_state helpers that wait_until the row is present before indexing and use them in toggle_keyword, toggle_keyword_case and toggle_regex — the same eventual-consistency pattern press_until and set_text_refound already apply elsewhere in the driver.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the AT-SPI flake that turned the
mainBuild Linux x64 leg red after #46 merged (run36803538442).Cause
toggle_keyword/toggle_keyword_case/toggle_regexread their target state from the panel-derived dict with a bareself.keywords()[text]/self.regexes()[pattern]. A just-added row can briefly disappear from the panel when the GUI's 1-second settings-poll reload rebuilds it, so that read races the rebuild and dies withKeyError. Both failures on main were exactly this (test_keyword_case_button→KeyError: 'Project Chimera'atgui_atspi.py:723,test_regex_toggle_and_delete→KeyError: '\bPN-\d{5}\b'at:797); the same commit passed the PR run and the arm64 leg. Product code is unaffected — the engine is the source of truth throughout.Fix
Add
_keyword_state/_regex_statehelpers thatwait_untilthe row is present before indexing, and use them in the three toggle helpers — the same eventual-consistency patternpress_untilandset_text_refoundalready apply for this reload in the driver.Notes
py_compile(the AT-SPI suite needs Linux + display + AT-SPI bindings, so it runs in CI, not on this Windows dev box)mainjob was also re-run separately to get the branch green again