diff options
author | Victor Stinner <vstinner@python.org> | 2020-04-27 18:53:37 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-27 18:53:37 (GMT) |
commit | 1a275013d1ecc2e3778d64fda86174b2f13d6969 (patch) | |
tree | 62fc2324c90a7d7417172487bd781794917a2555 /Lib/concurrent/futures | |
parent | b94dbd7ac34dc0c79512656eb17f6f07e09fca7a (diff) | |
download | cpython-1a275013d1ecc2e3778d64fda86174b2f13d6969.zip cpython-1a275013d1ecc2e3778d64fda86174b2f13d6969.tar.gz cpython-1a275013d1ecc2e3778d64fda86174b2f13d6969.tar.bz2 |
bpo-30966: concurrent.futures.Process.shutdown() closes queue (GH-19738)
Process.shutdown(wait=True) of concurrent.futures now closes
explicitly the result queue.
Diffstat (limited to 'Lib/concurrent/futures')
-rw-r--r-- | Lib/concurrent/futures/process.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/concurrent/futures/process.py b/Lib/concurrent/futures/process.py index 36355ae..8e9b69a 100644 --- a/Lib/concurrent/futures/process.py +++ b/Lib/concurrent/futures/process.py @@ -728,6 +728,8 @@ class ProcessPoolExecutor(_base.Executor): # objects that use file descriptors. self._executor_manager_thread = None self._call_queue = None + if self._result_queue is not None and wait: + self._result_queue.close() self._result_queue = None self._processes = None |