gh-110097: Fix flaky test_timeout in test_concurrent_futures.test_process_pool (gh-131108)

On heavily loaded systems, the launch of the workers to run
`time.sleep(0)` can take longer than the five second timeout.
This commit is contained in:
Sam Gross 2025-03-12 13:16:23 -04:00 committed by GitHub
parent f30376c650
commit 776ec1e167
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -69,7 +69,9 @@ def test_map_timeout(self):
else:
self.fail('expected TimeoutError')
self.assertEqual([None, None], results)
# gh-110097: On heavily loaded systems, the launch of the worker may
# take longer than the specified timeout.
self.assertIn(results, ([None, None], [None], []))
def test_shutdown_race_issue12456(self):
# Issue #12456: race condition at shutdown where trying to post a