Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-133089: Use original timeout value forTimeoutExpired when the funcsubprocess.run is called with a timeout#133103

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
gpshead merged 17 commits intopython:mainfromZheaoli:manjusaka/fix-subproces-timeout
May 5, 2025

Conversation

Zheaoli
Copy link
Contributor

@ZheaoliZheaoli commentedApr 28, 2025
edited by bedevere-appbot
Loading

…ut=None' when the timeout is zeroSigned-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
Copy link
Contributor

@StanFromIrelandStanFromIreland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

What about a negativetimeout? Why doeswait need this too?

This needs doc updates, and a test.

@Zheaoli
Copy link
ContributorAuthor

What about a negativetimeout?

How about raise ValueError when timeout is<=0

@StanFromIreland
Copy link
Contributor

StanFromIreland commentedApr 28, 2025
edited
Loading

Hmm, looking at bash functions I get conflicting results.timeout throws an error for negative values and has no limit on0, whereas other functions (e.g.read -t 0) actually use the limit (they stop instantly).

Yes, a value error is the way to go for negative timeouts.

Copy link
Member

@ZeroIntensityZeroIntensity left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I don't thinktimeout=0 should be treated the same astimeout=None. This isn't done anywhere else in the standard library. For example, usingasyncio as precedent:

importasyncioasyncdefmain():asyncwithasyncio.timeout(None):awaitasyncio.sleep(0)print("No timeout!")asyncwithasyncio.timeout(0):awaitasyncio.sleep(0)# TimeoutErrorasyncio.run(main())

I think it would be better to fix the negative time.

@Zheaoli
Copy link
ContributorAuthor

I don't thinktimeout=0 should be treated the same astimeout=None. This isn't done anywhere else in the standard library. For example, usingasyncio as precedent:

Make sense, I'll find a way to patch it

Signed-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
Copy link
Member

@gpsheadgpshead left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I think your documentation addition is useful, but the logic change is not what we want.

If you want a cleaner value in the TimeoutExpired error message in this situation, that could be done by catching andreplacing the info in the TimeoutExpired exception from Popen._communicate'sself.wait(timeout=self._remaining_time(endtime)) with the orig_timeout value that is known at that point..wait() itself cannot meaningfully know that value.

@bedevere-app
Copy link

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phraseI have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

Signed-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
@ZheaoliZheaoli changed the titlegh-133089: Makesubprocess.run's behavior is same with 'timeout=None' when the timeout is zerogh-133089: Use origional timeout value forTimeoutExpired when the funcsubprocess.run is called with a timeoutMay 4, 2025
Signed-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
Signed-off-by: Manjusaka <me@manjusaka.me>
@gpsheadgpshead added the needs backport to 3.13bugs and security fixes labelMay 5, 2025
@gpsheadgpshead changed the titlegh-133089: Use origional timeout value forTimeoutExpired when the funcsubprocess.run is called with a timeoutgh-133089: Use original timeout value forTimeoutExpired when the funcsubprocess.run is called with a timeoutMay 5, 2025
@gpsheadgpsheadenabled auto-merge (squash)May 5, 2025 01:04
@gpsheadgpshead merged commit2bbcaed intopython:mainMay 5, 2025
45 checks passed
@miss-islington-app
Copy link

Thanks@Zheaoli for the PR, and@gpshead for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

miss-islington pushed a commit to miss-islington/cpython that referenced this pull requestMay 5, 2025
… the func `subprocess.run` is called with a timeout (pythonGH-133103)(cherry picked from commit2bbcaed)Co-authored-by: Nadeshiko Manju <me@manjusaka.me>Signed-off-by: Manjusaka <me@manjusaka.me>Co-authored-by: Gregory P. Smith <greg@krypto.org>
@bedevere-app
Copy link

GH-133418 is a backport of this pull request to the3.13 branch.

@bedevere-appbedevere-appbot removed the needs backport to 3.13bugs and security fixes labelMay 5, 2025
gpshead added a commit that referenced this pull requestMay 5, 2025
…n the func `subprocess.run` is called with a timeout (GH-133103) (#133418)gh-133089: Use original timeout value for `TimeoutExpired` when the func `subprocess.run` is called with a timeout (GH-133103)(cherry picked from commit2bbcaed)Signed-off-by: Manjusaka <me@manjusaka.me>Co-authored-by: Nadeshiko Manju <me@manjusaka.me>Co-authored-by: Gregory P. Smith <greg@krypto.org>
@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbots390x RHEL8 LTO + PGO 3.x (tier-3) has failed when building commit2bbcaed.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/442/builds/9283) and take a look at the build logs.
  4. Check if the failure is related to this commit (2bbcaed) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/442/builds/9283

Failed tests:

  • test_frame
  • test_subprocess

Failed subtests:

  • test_timeout_exception - test.test_subprocess.ProcessTestCaseNoPoll.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.x.cstratak-rhel8-s390x.lto-pgo/build/Lib/test/test_subprocess.py", line171, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raised

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbots390x Fedora Stable Clang Installed 3.x (tier-3) has failed when building commit2bbcaed.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1645/builds/352) and take a look at the build logs.
  4. Check if the failure is related to this commit (2bbcaed) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1645/builds/352

Failed tests:

  • test_subprocess

Failed subtests:

  • test_timeout_exception - test.test_subprocess.ProcessTestCaseNoPoll.test_timeout_exception
  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x.clang-installed/build/target/lib/python3.14/test/test_subprocess.py", line177, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raisedTraceback (most recent call last):  File"/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x.clang-installed/build/target/lib/python3.14/test/test_subprocess.py", line171, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raised

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbots390x Fedora Stable LTO + PGO 3.x (tier-3) has failed when building commit2bbcaed.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1627/builds/352) and take a look at the build logs.
  4. Check if the failure is related to this commit (2bbcaed) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1627/builds/352

Failed tests:

  • test_subprocess

Failed subtests:

  • test_timeout_exception - test.test_subprocess.ProcessTestCaseNoPoll.test_timeout_exception
  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.x.cstratak-fedora-stable-s390x.lto-pgo/build/Lib/test/test_subprocess.py", line171, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raised

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotAMD64 Windows Server 2022 NoGIL 3.13 (tier-1) has failed when building commit3d1b8e2.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1488/builds/1266) and take a look at the build logs.
  4. Check if the failure is related to this commit (3d1b8e2) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1488/builds/1266

Failed tests:

  • test_subprocess

Failed subtests:

  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"C:\Users\Administrator\buildarea\3.13.itamaro-win64-srv-22-aws.x64.nogil\build\Lib\test\test_subprocess.py", line166, intest_timeout_exception    subprocess.run(['echo','hi'],timeout=-1)~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  File"C:\Users\Administrator\buildarea\3.13.itamaro-win64-srv-22-aws.x64.nogil\build\Lib\subprocess.py", line554, inrunwith Popen(*popenargs,**kwargs)as process:~~~~~^^^^^^^^^^^^^^^^^^^^^^  File"C:\Users\Administrator\buildarea\3.13.itamaro-win64-srv-22-aws.x64.nogil\build\Lib\subprocess.py", line1039, in__init__self._execute_child(args, executable, preexec_fn, close_fds,~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^                        pass_fds, cwd, env,^^^^^^^^^^^^^^^^^^^...<5 lines>...                        gid, gids, uid, umask,^^^^^^^^^^^^^^^^^^^^^^                        start_new_session, process_group)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  File"C:\Users\Administrator\buildarea\3.13.itamaro-win64-srv-22-aws.x64.nogil\build\Lib\subprocess.py", line1554, in_execute_child    hp, ht, pid, tid= _winapi.CreateProcess(executable, args,~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^# no special security^^^^^^^^^^^^^^^^^^^^^...<4 lines>...                             cwd,^^^^                             startupinfo)^^^^^^^^^^^^FileNotFoundError:[WinError 2] The system cannot find the file specified

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbots390x Fedora Stable 3.13 (tier-3) has failed when building commit3d1b8e2.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1658/builds/128) and take a look at the build logs.
  4. Check if the failure is related to this commit (3d1b8e2) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1658/builds/128

Failed tests:

  • test_os
  • test_subprocess

Failed subtests:

  • test_timerfd_select - test.test_os.TimerfdTests.test_timerfd_select
  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception
  • test_timeout_exception - test.test_subprocess.ProcessTestCaseNoPoll.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.13.cstratak-fedora-stable-s390x/build/Lib/test/test_os.py", line4288, intest_timerfd_selectself.assertEqual(self.read_count_signaled(fd),1)~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:2 != 1Traceback (most recent call last):  File"/home/buildbot/buildarea/3.13.cstratak-fedora-stable-s390x/build/Lib/test/test_subprocess.py", line170, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raised

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbots390x RHEL9 LTO 3.13 (tier-3) has failed when building commit3d1b8e2.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1577/builds/702) and take a look at the build logs.
  4. Check if the failure is related to this commit (3d1b8e2) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1577/builds/702

Failed tests:

  • test_subprocess

Failed subtests:

  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.13.cstratak-rhel9-s390x.lto/build/Lib/test/test_subprocess.py", line170, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raised

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbots390x Fedora Stable Clang 3.13 (tier-3) has failed when building commit3d1b8e2.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1667/builds/128) and take a look at the build logs.
  4. Check if the failure is related to this commit (3d1b8e2) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1667/builds/128

Failed tests:

  • test_subprocess

Failed subtests:

  • test_timeout_exception - test.test_subprocess.ProcessTestCaseNoPoll.test_timeout_exception
  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.13.cstratak-fedora-stable-s390x.clang/build/Lib/test/test_subprocess.py", line176, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raisedTraceback (most recent call last):  File"/home/buildbot/buildarea/3.13.cstratak-fedora-stable-s390x.clang/build/Lib/test/test_subprocess.py", line170, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raised

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotAMD64 Ubuntu Shared 3.x (tier-1) has failed when building commit2bbcaed.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/506/builds/10590) and take a look at the build logs.
  4. Check if the failure is related to this commit (2bbcaed) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/506/builds/10590

Failed tests:

  • test_subprocess

Failed subtests:

  • test_timeout_exception - test.test_subprocess.ProcessTestCaseNoPoll.test_timeout_exception
  • test_remote_stack_trace - test.test_external_inspection.TestGetStackTrace.test_remote_stack_trace
  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/test/test_subprocess.py", line171, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raisedTraceback (most recent call last):  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/test/test_external_inspection.py", line104, intest_remote_stack_traceself.assertEqual(stack_trace, expected_stack_trace)~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Lists differ: [('fo[62 chars]y', 14), ('baz', '/tmp/test_python_m2xu4jch/tm[186 chars] 17)] != [('fo[62 chars]y', 15), ('baz', '/tmp/test_python_m2xu4jch/tm[186 chars] 17)]Traceback (most recent call last):  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/test/test_subprocess.py", line177, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raised

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbots390x Fedora Stable Refleaks 3.13 (tier-3) has failed when building commit3d1b8e2.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1662/builds/133) and take a look at the build logs.
  4. Check if the failure is related to this commit (3d1b8e2) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1662/builds/133

Failed tests:

  • test_subprocess
  • test_socket

Failed subtests:

  • testSourceAddress - test.test_socket.NetworkConnectionAttributesTest.testSourceAddress
  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/home/buildbot/buildarea/3.13.cstratak-fedora-stable-s390x.refleak/build/Lib/test/test_subprocess.py", line170, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raisedTraceback (most recent call last):  File"/home/buildbot/buildarea/3.13.cstratak-fedora-stable-s390x.refleak/build/Lib/test/test_socket.py", line417, inraise_queued_exceptionraiseself.queue.get()  File"/home/buildbot/buildarea/3.13.cstratak-fedora-stable-s390x.refleak/build/Lib/test/test_socket.py", line454, inclientRun    test_func()~~~~~~~~~^^  File"/home/buildbot/buildarea/3.13.cstratak-fedora-stable-s390x.refleak/build/Lib/test/test_socket.py", line5783, in_testSourceAddressself.assertEqual(self.cli.getsockname()[1],self.source_port)~~~~~~~~~~~~~~~~~~~~^^OSError:[Errno 9] Bad file descriptor

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotAMD64 FreeBSD Refleaks 3.13 (tier-3) has failed when building commit3d1b8e2.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1615/builds/733) and take a look at the build logs.
  4. Check if the failure is related to this commit (3d1b8e2) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/#/builders/1615/builds/733

Failed tests:

  • test_subprocess

Failed subtests:

  • test_timeout_exception - test.test_subprocess.ProcessTestCaseNoPoll.test_timeout_exception
  • test_timeout_exception - test.test_subprocess.ProcessTestCase.test_timeout_exception

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/buildbot/buildarea/3.13.ware-freebsd.refleak/build/Lib/test/test_subprocess.py", line176, intest_timeout_exceptionself.fail("Expected TimeoutExpired exception not raised")~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^AssertionError:Expected TimeoutExpired exception not raised

gpshead added a commit to gpshead/cpython that referenced this pull requestMay 5, 2025
The few buildbot failures onpython#133103are possibly just due to racing a child process launch and exit?
gpshead added a commit that referenced this pull requestMay 5, 2025
The few buildbot failures on#133103are possibly just due to racing a child process launch and exit?
miss-islington pushed a commit to miss-islington/cpython that referenced this pull requestMay 5, 2025
…GH-133420)The few buildbot failures onpython#133103are possibly just due to racing a child process launch and exit?(cherry picked from commitb64aa30)Co-authored-by: Gregory P. Smith <greg@krypto.org>
gpshead added a commit that referenced this pull requestMay 5, 2025
…H-133420) (#133421)[tests] test_subprocess maybe avoid a timeout race condition? (GH-133420)The few buildbot failures on#133103are possibly just due to racing a child process launch and exit?(cherry picked from commitb64aa30)Co-authored-by: Gregory P. Smith <greg@krypto.org>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@gpsheadgpsheadgpshead approved these changes

@StanFromIrelandStanFromIrelandAwaiting requested review from StanFromIreland

@ZeroIntensityZeroIntensityAwaiting requested review from ZeroIntensity

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

Negative run-time reported bysubprocess.run'sTimeoutExpired exception when settingtimeout=0
5 participants
@Zheaoli@StanFromIreland@bedevere-bot@gpshead@ZeroIntensity

[8]ページ先頭

©2009-2025 Movatter.jp