summaryrefslogtreecommitdiffstats
path: root/Lib/concurrent
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2023-09-26 07:06:07 (GMT)
committerGitHub <noreply@github.com>2023-09-26 07:06:07 (GMT)
commit0b4e090422db5f959184353d53552d1675f74212 (patch)
treec6e7757039d019b299cf1082c2d815eae1f1392c /Lib/concurrent
parent4091deba88946841044b0a54090492a2fd903d42 (diff)
downloadcpython-0b4e090422db5f959184353d53552d1675f74212.zip
cpython-0b4e090422db5f959184353d53552d1675f74212.tar.gz
cpython-0b4e090422db5f959184353d53552d1675f74212.tar.bz2
gh-109370: Fix unexpected traceback output in test_concurrent_futures (GH-109780)
Follow-up of gh-107219. * Only close the connection writer on Windows. * Also use existing constant _winapi.ERROR_OPERATION_ABORTED instead of WSA_OPERATION_ABORTED.
Diffstat (limited to 'Lib/concurrent')
-rw-r--r--Lib/concurrent/futures/process.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/concurrent/futures/process.py b/Lib/concurrent/futures/process.py
index 48d8db3..011e79a 100644
--- a/Lib/concurrent/futures/process.py
+++ b/Lib/concurrent/futures/process.py
@@ -521,7 +521,8 @@ class _ExecutorManagerThread(threading.Thread):
# gh-107219: Close the connection writer which can unblock
# Queue._feed() if it was stuck in send_bytes().
- self.call_queue._writer.close()
+ if sys.platform == 'win32':
+ self.call_queue._writer.close()
# clean up resources
self.join_executor_internals()