]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-112800: Ignore PermissionError on SubprocessTransport.close() in asyncio (#112803)
authorAllison Karlitskaya <allison.karlitskaya@redhat.com>
Sun, 24 Dec 2023 00:43:39 +0000 (01:43 +0100)
committerGitHub <noreply@github.com>
Sun, 24 Dec 2023 00:43:39 +0000 (16:43 -0800)
commit0187a7e4ec9550a6e35dd06b26f22863520242ab
tree0113b3448a127d2f00b8eccf2eca27aa06e524ea
parentca71987f4e3be56a369a1dd57763c6077b3c4899
gh-112800: Ignore PermissionError on SubprocessTransport.close() in asyncio (#112803)

In case the spawned process is setuid, we may not be able to send
signals to it, in which case our .kill() call will raise
PermissionError.

Ignore that in order to avoid .close() raising an exception.  Hopefully
the process will exit as a result of receiving EOF on its stdin.
Lib/asyncio/base_subprocess.py
Misc/NEWS.d/next/Library/2023-12-06-16-01-33.gh-issue-112800.TNsGJ-.rst [new file with mode: 0644]