Commit Graph

4 Commits

Author SHA1 Message Date
Sam Gross 760872efec
gh-125451: Fix deadlock in ProcessPoolExecutor shutdown (#125492)
There was a deadlock when `ProcessPoolExecutor` shuts down at the same
time that a queueing thread handles an error processing a task.

Don't use `_shutdown_lock` to protect the `_ThreadWakeup` pipes -- use
an internal lock instead. This fixes the ordering deadlock where the
`ExecutorManagerThread` holds the `_shutdown_lock` and joins the
queueing thread, while the queueing thread is attempting to acquire the
`_shutdown_lock` while closing the `_ThreadWakeup`.
2024-10-16 11:39:17 -04:00
Victor Stinner c6e8ff86b2
gh-125451: Skip concurrent.futures test_processes_terminate() (#125533)
The test hangs randomly. It tries to serialize local lock and a local
function which are not possible.
2024-10-15 15:42:55 +00:00
Sam Gross 7d1abe9502
gh-116682: stdout may be empty in test_cancel_futures_wait_false (#116683)
If the `shutdown()` call happens before the worker thread starts executing
the task, then nothing will be printed to stdout.
2024-03-12 20:11:58 -04:00
Victor Stinner aa6f787faa
gh-108388: Convert test_concurrent_futures to package (#108401)
Convert test_concurrent_futures to a package of sub-tests.
2023-08-24 19:21:44 +02:00