-
-
Notifications
You must be signed in to change notification settings - Fork 31.1k
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
test_concurrent_futures: test_as_completed.test_future_times_out() fails on GHA Windows x86 CI #109565
Comments
Test also failed on s390x Fedora 3.x: https://buildbot.python.org/all/#/builders/223/builds/4511
|
I guess this would fix it: with self.subTest(timeout):
- future = self.executor.submit(time.sleep, 0.1)
+ future = self.executor.submit(time.sleep, 10.0)
completed_futures = set()
try: I don't think the short sleep serves any testing purpose here, it just makes the test more likely to fail if there is any unexpected CPU contention. |
The problem is that the test waits cleanly until the future completes, and so the test takes 10 seconds with your change, instead of 100 ms (100x slower). |
as_completed() uses a timeout of 100 ms instead of 10 ms. Windows monotonic clock resolution is around 15.6 ms.
as_completed() uses a timeout of 100 ms instead of 10 ms. Windows monotonic clock resolution is around 15.6 ms.
I proposed PR #109949 to fix this test. |
as_completed() uses a timeout of 100 ms instead of 10 ms. Windows monotonic clock resolution is around 15.6 ms.
…onGH-109949) as_completed() uses a timeout of 100 ms instead of 10 ms. Windows monotonic clock resolution is around 15.6 ms. (cherry picked from commit b1aebf1) Co-authored-by: Victor Stinner <[email protected]>
…on#109949) as_completed() uses a timeout of 100 ms instead of 10 ms. Windows monotonic clock resolution is around 15.6 ms.
…on#109949) as_completed() uses a timeout of 100 ms instead of 10 ms. Windows monotonic clock resolution is around 15.6 ms.
Windows x86:
build: https://github.com/python/cpython/actions/runs/6225761937/job/16896880945?pr=108965
The test fails randomly. It passed when re-run in verbose mode in a fresh process:
Linked PRs
The text was updated successfully, but these errors were encountered: