# still failing
for _ in range(n_times):
mock_self.display.simulate_input(-1)
- if n_times >= 500:
- mock_self.display.simulate_input(ord('q'))
+ mock_self.display.simulate_input(ord('q'))
def test_run_failed_module_live(self):
"""Test that running a existing module that fails exits with clean error."""
--- /dev/null
+Fix hang in
+``test.test_profiling.test_sampling_profiler.test_live_collector_ui.TestLiveModeErrors.test_run_failed_script_live``
+on slow buildbots. The test now always queues a final ``q`` keystroke so the
+live TUI loop exits even when the profiler collects enough samples to enter
+the post-finished input loop.