Prior to being able to call `isatty()` or `ttyname()` on a new subsidiary pty, the "ptem" module must be pushed there. This patch comes from OmniOS. --- Python-3.14.0/Lib/test/test_os.py.orig +++ Python-3.14.0/Lib/test/test_os.py @@ -4879,6 +4879,7 @@ son_path = os.ptsname(mother_fd) son_fd = os.open(son_path, os.O_RDWR|os.O_NOCTTY) self.addCleanup(os.close, son_fd) + fcntl.ioctl(son_fd, fcntl.I_PUSH, "ptem") self.assertEqual(os.ptsname(mother_fd), os.ttyname(son_fd)) @unittest.skipUnless(hasattr(os, 'spawnl'), "need os.spawnl()")