Xavier de Gaye added the comment:
The infinite loop may occur if one of the functions called by
PyRun_InteractiveOneObject() returns persistently -1. This may be the case when
there is no more memory and is handled by issue 30696.
It is not possible anymore to reproduce
Mark Lawrence added the comment:
I've failed to reproduce this using latest default on Windows 7, would someone
else like to try please.
--
nosy: +BreamoreBoy
versions: +Python 3.4, Python 3.5 -Python 3.2, Python 3.3
___
Python tracker
Tim Lesher tles...@gmail.com added the comment:
Corrected const warning in previous patch.
--
Added file: http://bugs.python.org/file24794/8070-use-default-encoding-2.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8070
Changes by Éric Araujo mer...@netwok.org:
--
versions: +Python 3.3 -Python 2.6, Python 3.1
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8070
___
Tim Lesher tles...@gmail.com added the comment:
Updated patch: use Py_FileSystemDefaultEncoding (if possible) when sys.stdin
is (or becomes) invalid; if none, then fails without entering infinite loop.
Docs for PyRun_InteractiveLoopFlags have been updated.
--
Added file:
Tim Lesher tles...@gmail.com added the comment:
Victor: would you object to ysj.ray's solution?
I don't think it was an option when we last looked at this issue.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8070
STINNER Victor victor.stin...@haypocalc.com added the comment:
Issue #11730 has been marked as duplicate.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8070
___
ysj.ray ysj@gmail.com added the comment:
I'd prefer not exit program but try to use Py_FileSystemDefaultEncoding as enc
when sys.stdin is invalid. On most cases, setting sys.stdin to some other
invalid value does means the program could not continue running.
--
ysj.ray ysj@gmail.com added the comment:
On most cases, setting sys.stdin to some other invalid value does means the
program could not continue running.
Sorry, it should be:
On most cases, setting sys.stdin to some other invalid value does not mean the
program could not continue
Changes by Ray.Allen ysj@gmail.com:
--
nosy: +ysj.ray
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8070
___
___
Python-bugs-list mailing list
STINNER Victor victor.stin...@haypocalc.com added the comment:
tlesher If you don't have time to update the patch, let me know and I'll put
one together.
I would be happy if you write a new patch :-)
--
___
Python tracker rep...@bugs.python.org
STINNER Victor victor.stin...@haypocalc.com added the comment:
I don't have time to write a better patch, please improve mine :-)
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8070
___
Tim Lesher tles...@gmail.com added the comment:
I just hit this one myself, and was about to write a bug and patch.
On reviewing the patch:
1. This really has the same issue as the original code: it detects one of a few
known return values, and will infinitely loop on an unexpected return
STINNER Victor victor.stin...@haypocalc.com added the comment:
PyRun_InteractiveLoop() doesn't specify the possible return value. It's maybe
because it's always zero and that the error are not handled :-)
http://docs.python.org/c-api/veryhigh.html#PyRun_InteractiveLoop
14 matches
Mail list logo