https://github.com/python/cpython/commit/d23b06b2a8becc6619e3112468f8c94500d7e470
commit: d23b06b2a8becc6619e3112468f8c94500d7e470
branch: 3.15
author: Miss Islington (bot) <[email protected]>
committer: pablogsal <[email protected]>
date: 2026-05-25T18:46:19Z
summary:
[3.15] gh-150387: Fix hang in test_run_failed_script_live on slow buildbots
(GH-150405) (#150420)
files:
A Misc/NEWS.d/next/Tests/2026-05-25-15-39-53.gh-issue-150387.yzZ7jq.rst
M Lib/test/test_profiling/test_sampling_profiler/test_live_collector_ui.py
diff --git
a/Lib/test/test_profiling/test_sampling_profiler/test_live_collector_ui.py
b/Lib/test/test_profiling/test_sampling_profiler/test_live_collector_ui.py
index c0d39f487c8cbdf..59373a8d00c03cf 100644
--- a/Lib/test/test_profiling/test_sampling_profiler/test_live_collector_ui.py
+++ b/Lib/test/test_profiling/test_sampling_profiler/test_live_collector_ui.py
@@ -835,8 +835,7 @@ def mock_init_curses_side_effect(self, n_times, mock_self,
stdscr):
# 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."""
diff --git
a/Misc/NEWS.d/next/Tests/2026-05-25-15-39-53.gh-issue-150387.yzZ7jq.rst
b/Misc/NEWS.d/next/Tests/2026-05-25-15-39-53.gh-issue-150387.yzZ7jq.rst
new file mode 100644
index 000000000000000..663a357a1792042
--- /dev/null
+++ b/Misc/NEWS.d/next/Tests/2026-05-25-15-39-53.gh-issue-150387.yzZ7jq.rst
@@ -0,0 +1,5 @@
+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.
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]