[issue11650] Faulty RESTART/EINTR handling in Parser/myreadline.c

Davide Rizzo report at bugs.python.org
Tue Mar 29 13:17:35 CEST 2011


Davide Rizzo <sorcio at gmail.com> added the comment:

An effective way to automate user interaction tests is by using pseudo-terminals. The attached test uses Pexpect and bash as tools to test the issue and demonstrates the bug on affected builds/platforms. There are a number of (possibly related) other issues that may require similar testing.

Pexpect is a nice tool to automate testing over ptys, but it is Python 2. I had to run the test on Python 3.3 through the installed Python 2 interpter. My thought: the smallest useful subset of Pexpect can be ported to Py3 and maintained within Python. Or alternatively an equally useful minimal implementation of the same features. Note that most of Pexpect is already tested.

I've used bash to test this one issue because it was ready and I could rely on bash jobs handling. I don't know how good is to expect bash to be on the system or whether any sh-like shell is compatible.

There is a WinPexpect which supposedly does the same thing on Windows in a native way. I couldn't get the time to try it out, but it includes a modified version of Pexpect and claims Py3 compatibility.

Also, I don't really understand sdaoden ascii art messages.

Let me know if someone wants to work on this with me. :)

----------
Added file: http://bugs.python.org/file21450/testrepl.py

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11650>
_______________________________________


More information about the Python-bugs-list mailing list