diff --git a/Lib/test/test_io.py b/Lib/test/test_io.py index d1973e5f3ee..1ea57ac11e7 100644 --- a/Lib/test/test_io.py +++ b/Lib/test/test_io.py @@ -2597,6 +2597,7 @@ class SignalsTest(unittest.TestCase): t = threading.Thread(target=_read) t.daemon = True r, w = os.pipe() + fdopen_kwargs["closefd"] = False try: wio = self.io.open(w, **fdopen_kwargs) t.start()