From 862bc07280b89bbc0b2e462f69516490f8431057 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A1szl=C3=B3=20Kiss=20Koll=C3=A1r?= Date: Mon, 1 Jun 2026 22:01:48 +0100 Subject: [PATCH] Remove '-d 1' in test_script_error_treatment Fix race condition in test_script_error_treatment in test_sampling_profiler. An overloaded system can end up running the subprocess under the test so slowly that it never reaches the point of emitting the error message when the one second duration in the profiler expires. We can just drop the `-d 1` argument to let the profiler wait until the target process finishes. --- .../test_profiling/test_sampling_profiler/test_integration.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/Lib/test/test_profiling/test_sampling_profiler/test_integration.py b/Lib/test/test_profiling/test_sampling_profiler/test_integration.py index c6731e956391a91..3487647b76683ee 100644 --- a/Lib/test/test_profiling/test_sampling_profiler/test_integration.py +++ b/Lib/test/test_profiling/test_sampling_profiler/test_integration.py @@ -686,8 +686,6 @@ def test_script_error_treatment(self): "-m", "profiling.sampling.cli", "run", - "-d", - "1", script_file.name, ], capture_output=True,