Skip to content

[3.8] bpo-40140: test_builtin.PtyTests registers SIGHUP handler (GH-19314) #19316

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 3, 2020
Merged

[3.8] bpo-40140: test_builtin.PtyTests registers SIGHUP handler (GH-19314) #19316

merged 1 commit into from
Apr 3, 2020

Conversation

vstinner
Copy link
Member

@vstinner vstinner commented Apr 2, 2020

test_builtin.PtyTests now registers an handler for SIGHUP signal.
Closing the PTY file descriptor can emit a SIGHUP signal: just ignore
it.

run_child() now also closes the PTY file descriptor before waiting
for the process completition, otherwise the test hangs on AIX.

(cherry picked from commit 7a51a7e)

https://bugs.python.org/issue40140

test_builtin.PtyTests now registers an handler for SIGHUP signal.
Closing the PTY file descriptor can emit a SIGHUP signal: just ignore
it.

run_child() now also closes the PTY file descriptor before waiting
for the process completition, otherwise the test hangs on AIX.

(cherry picked from commit 7a51a7e)
@vstinner
Copy link
Member Author

vstinner commented Apr 2, 2020

I will wait for AIX buildbots to confirm that my change also fix the issue on AIX before merging this backport:
https://bugs.python.org/issue40155

@vstinner vstinner merged commit 745bd91 into python:3.8 Apr 3, 2020
@vstinner vstinner deleted the pty_tests_sighup38 branch April 3, 2020 00:11
@miss-islington
Copy link
Contributor

Thanks @vstinner for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7.
🐍🍒⛏🤖

@miss-islington
Copy link
Contributor

Sorry @vstinner, I had trouble checking out the 3.7 backport branch.
Please backport using cherry_picker on command line.
cherry_picker 745bd91bab8e57c52d63a2d541465551d7551f78 3.7

@bedevere-bot
Copy link

GH-19318 is a backport of this pull request to the 3.7 branch.

vstinner added a commit that referenced this pull request Apr 3, 2020
…H-19316) (GH-19318)

test_builtin.PtyTests now registers an handler for SIGHUP signal.
Closing the PTY file descriptor can emit a SIGHUP signal: just ignore
it.

run_child() now also closes the PTY file descriptor before waiting
for the process completition, otherwise the test hangs on AIX.

(cherry picked from commit 7a51a7e)
(cherry picked from commit 745bd91)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip news tests Tests in the Lib/test dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants