aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2024-08-31 13:08:35 -0700
committerZac Medico <zmedico@gentoo.org>2024-08-31 23:59:44 -0700
commitb30ddb1913e8aa2947d20e43f455d2060aa6257f (patch)
tree176ff7ed289f3b224d8e6a38c6a778682bd7def9
parentasyncio: Use default ensure_future implementation when possible (diff)
downloadportage-b30ddb1913e8aa2947d20e43f455d2060aa6257f.tar.gz
portage-b30ddb1913e8aa2947d20e43f455d2060aa6257f.tar.bz2
portage-b30ddb1913e8aa2947d20e43f455d2060aa6257f.zip
asyncio: Avoid _wrap_loop prior to create_subprocess_exec
Bug: https://bugs.gentoo.org/761538 Signed-off-by: Zac Medico <zmedico@gentoo.org>
-rw-r--r--lib/portage/util/futures/_asyncio/__init__.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/portage/util/futures/_asyncio/__init__.py b/lib/portage/util/futures/_asyncio/__init__.py
index 48d9b6810..4cf337998 100644
--- a/lib/portage/util/futures/_asyncio/__init__.py
+++ b/lib/portage/util/futures/_asyncio/__init__.py
@@ -119,7 +119,7 @@ def run(coro):
run.__doc__ = _real_asyncio.run.__doc__
-def create_subprocess_exec(*args, **kwargs):
+def create_subprocess_exec(*args, loop=None, **kwargs):
"""
Create a subprocess.
@@ -140,7 +140,6 @@ def create_subprocess_exec(*args, **kwargs):
@rtype: asyncio.subprocess.Process (or compatible)
@return: asyncio.subprocess.Process interface
"""
- loop = _wrap_loop(kwargs.pop("loop", None))
# Python 3.4 and later implement PEP 446, which makes newly
# created file descriptors non-inheritable by default.
kwargs.setdefault("close_fds", False)