[issue24891] python aborts running under nohup
Yi Ding added the comment: test.sh attached -- Added file: http://bugs.python.org/file40210/test.sh ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24891] python aborts running under nohup
New submission from Yi Ding: Looks like this bug https://bugs.python.org/issue7111 has resurfaced in python3 (python 2.6 works as far as I can tell) at least on Macs. I've attached a simple test script. Steps: 1. SSH to remote server. 2. Run nohup ./test.sh 3. exit SSH. 4. SSH back in and see that there are a bunch of errors in your nohup.out file. -- files: test.py messages: 248797 nosy: Yi Ding priority: normal severity: normal status: open title: python aborts running under nohup type: crash versions: Python 3.4 Added file: http://bugs.python.org/file40209/test.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24891] python aborts running under nohup
STINNER Victor added the comment: I can reproduce the bug with gdb if the file descriptor 0 is closed before calling: std = create_stdio(iomod, fd, 0, stdin, encoding, errors); and after the following lines were called: fd = fileno(stdin); if (!is_valid_fd(fd)) { In initstdio () at Python/pylifecycle.c:1156. create_stdio() fails in FileIO constructor, on the line: if (_Py_fstat(self-fd, fdfstat) 0) of _io_FileIO___init___impl() at Modules/_io/fileio.c:480 It's a corner case of the issue #7111, I would call it a race condition. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24891] python aborts running under nohup
STINNER Victor added the comment: Python 2 is not affected, PyFile_FromFile() doesn't check if the file descriptor is valid. On Python 3, we call fstat() to check the block size of the file descriptor to optimize buffering. -- versions: +Python 3.5, Python 3.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24891] python aborts running under nohup
Yi Ding added the comment: Fatal Python error: Py_Initialize: can't initialize sys standard streams OSError: [Errno 9] Bad file descriptor ./test.sh: line 4: 49632 Abort trap: 6 python3 test.py -o hello.txt -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24891] python aborts running under nohup
Robert Collins added the comment: What sort of errors? -- nosy: +rbcollins ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24891] python aborts running under nohup
STINNER Victor added the comment: I'm unable to reproduce the issue on Linux with Python 3.4.2. -- components: +Macintosh nosy: +haypo, ned.deily, ronaldoussoren ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24891] python aborts running under nohup
Yi Ding added the comment: That's from my nohup.out. It might be a Mac OS specific thing. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24891] python aborts running under nohup
Changes by STINNER Victor victor.stin...@gmail.com: -- priority: normal - low ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24891 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com