Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gh-128041: Add terminate_workers and kill_workers methods to ProcessPoolExecutor #130849

Merged
merged 6 commits into from
Mar 5, 2025

Conversation

csm10495
Copy link
Contributor

@csm10495 csm10495 commented Mar 4, 2025

Provides a way to forcefully stop all the workers in the pool

Typically this would be used as a last effort to stop all workers if unable to shutdown / join in the expected way.

This is a newer version of #128043 that includes fixes for transient issues seen in CI.


📚 Documentation preview 📚: https://cpython-previews--130849.org.readthedocs.build/

…o ProcessPoolExecutor

Add some fixes to tests to make them no longer transient
@gpshead gpshead added the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Mar 4, 2025
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @gpshead for commit ec7599c 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F130849%2Fmerge

If you want to schedule another build, you need to add the 🔨 test-with-buildbots label again.

@bedevere-bot bedevere-bot removed the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Mar 4, 2025
@csm10495
Copy link
Contributor Author

csm10495 commented Mar 4, 2025

I've run

./python.exe -m test test.test_concurrent_futures.test_process_pool  -vvv --fail-env-changed

75 times in a row now without a failure. @colesbury mind checking again. Thanks for the feedback!

@csm10495 csm10495 requested a review from colesbury March 4, 2025 18:59
@colesbury colesbury added the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Mar 4, 2025
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @colesbury for commit 92a2d72 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F130849%2Fmerge

If you want to schedule another build, you need to add the 🔨 test-with-buildbots label again.

@bedevere-bot bedevere-bot removed the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Mar 4, 2025
Copy link
Contributor

@colesbury colesbury left a comment

Choose a reason for hiding this comment

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

Thanks @csm10495, this looks good to me!

I rescheduled the buildbots and I'm also running some stress tests locally. So far, it looks good!

@csm10495
Copy link
Contributor Author

csm10495 commented Mar 5, 2025

I don't think those buildbot failures are related, but not 100% sure.

@gpshead gpshead merged commit ba05a4e into python:main Mar 5, 2025
116 of 120 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants