diff options
author | Martin Krizek <martin.krizek@gmail.com> | 2021-04-06 18:26:52 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-06 11:26:52 -0500 |
commit | 96f94c0fef18cf25f772a2b241b9c4ce9ab9b74e (patch) | |
tree | 9025418cdcb631cf2b1cda923f605f4b4604bac5 /lib/ansible/executor/process | |
parent | d1842afd59ea087b0d2c5081d1c6cbc295c57aba (diff) | |
download | ansible-96f94c0fef18cf25f772a2b241b9c4ce9ab9b74e.tar.gz |
Use a file-like obj for stdout/stderr for deadlock workaround (#74156)
Fixes #74149
Diffstat (limited to 'lib/ansible/executor/process')
-rw-r--r-- | lib/ansible/executor/process/worker.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/ansible/executor/process/worker.py b/lib/ansible/executor/process/worker.py index 983df45bca..510928c0ed 100644 --- a/lib/ansible/executor/process/worker.py +++ b/lib/ansible/executor/process/worker.py @@ -145,8 +145,7 @@ class WorkerProcess(multiprocessing_context.Process): # TODO: Evaluate overhauling ``Display`` to not write directly to stdout # and evaluate migrating away from the ``fork`` multiprocessing start method. if sys.version_info[0] >= 3: - sys.stdout = os.devnull - sys.stderr = os.devnull + sys.stdout = sys.stderr = open(os.devnull, 'w') def _run(self): ''' |