Repository navigation
studio: fix tests turning main CI red/flaky (kill-process, install overrides, UI re-login) - #6419
Merged
Merged
Conversation
#6377 added a self._stats_logger cleanup step to _kill_process's finally block. test_kill_process_records_timestamp_on_actual_kill (added in #6400) builds the backend via __new__, which bypasses __init__ where _stats_logger is set, so once both landed on main the test raised AttributeError: 'LlamaCppBackend' object has no attribute '_stats_logger'. Set _stats_logger on the hand-built backend, mirroring __init__, so the kill path's finally has the attribute it expects.
Contributor
There was a problem hiding this comment.
Code Review
This pull request updates the test setup in test_llama_cpp_wait_for_vram_settle.py by initializing backend._stats_logger to None to prevent errors when _kill_process attempts to stop it in its finally block. There are no review comments, so I have no feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
#6400 moved the torchao dependency override from a fixed pin in overrides.txt to a torch-matched spec installed via --force-reinstall (_select_torchao_spec), and turned overrides.txt into a comment-only pointer. It updated the Windows variant (test_windows_only_includes_overrides) to check for --reinstall, but left test_normal_linux_includes_overrides asserting overrides.txt is installed, which no longer happens. Check for the override step (--reinstall) instead, matching the Windows test.
The Shutdown step re-logs in after a CLI password rotation that revoked the prior
token. The SPA auth guard can client-side-redirect mid-navigation against the
stale token, aborting page.goto("/login") with net::ERR_ABORTED. It is a race
(passes on main most of the time). Resolve on domcontentloaded and tolerate the
abort, relying on the password-field wait that follows to confirm we reached
/login, matching the wait_until used by the other navigations in this file.
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.
Summary
mainCI is red/flaky from three tests left behind by the recent merge wave (#6377, #6400, #6405). None is a real product regression; each tests removed/old behavior or races a navigation. This PR makes the affected jobs green.1.
Repo tests (CPU)/ Python matrix:test_kill_process_records_timestamp_on_actual_killAttributeError: 'LlamaCppBackend' object has no attribute '_stats_logger'. #6377 added aself._stats_loggercleanup to_kill_process()'sfinally; #6400's test builds the backend viaLlamaCppBackend.__new__(...), bypassing__init__where_stats_loggeris set. Fix: set_stats_loggeron the hand-built backend, alongside the other attributes it already seeds. Production code unchanged.2.
Repo tests (CPU):test_normal_linux_includes_overridesoverrides.txt should be called on normal Linux. #6400 moved the torchao override from a fixed pin inoverrides.txtto a torch-matched spec installed via--force-reinstall(_select_torchao_spec), leavingoverrides.txtas a comment-only pointer. It updated the Windows variant to assert--reinstallbut not the Linux one. Fix: assert the override step (--reinstall) on Linux too, matching the Windows test and the real install behavior.3.
Chat UI Tests: flakynet::ERR_ABORTEDon/loginThe Shutdown step re-logs in after a CLI password rotation that revoked the prior token. The SPA auth guard can client-side-redirect mid-navigation against the stale token, aborting
page.goto("/login")withnet::ERR_ABORTED(a race; passes onmainmost of the time). Fix: resolve ondomcontentloadedand tolerate the abort, relying on the password-field wait that follows to confirm/login(matching thewait_untilother navigations in this file already use).Verification
The Chat UI script is a full live-Studio + browser e2e flow, so the navigation change is verified by
py_compileand the standard Playwright robustness pattern rather than a local run.