Bug: Readline getting stuck on Linux and Solaris
quinn at lira.ugcs.caltech.edu
Thu Dec 7 06:34:14 CET 2000
On 06 Dec 2000 20:08:41 +0000, Michael Hudson <mwh21 at cam.ac.uk> wrote:
>sragsdale at my-deja.com writes:
>> In article <lxk8zqwupy2.fsf at ioasun3.epfl.ch>,
>> Jan Kybic <Jan.Kybic at epfl.ch> wrote:
>> > Hi,
>> > I am using Python 2.0, I downloaded it in the RPM form and I
>> > also compiled it from source on both Linux RedHat 6.2 and Solaris. In
>> > both cases, when I have the readline module enabled, the keyboard
>> > input gets stuck.
>> I'm having similar problems with Python 2.0 hanging in Irix. What's
>> most annoying is that this happens on the Python command line when you
>> hit control-C. In Python 1.5.2 this is a KeyboardInterrupt event. In
>> Python 2.0 this hangs the interpreter which starts using 100% of the
>> processor. I can't kill it with more control-C's. If I disable the
>> readline (4.1) module this problem goes away. This problem does not
>> happen in Linux 2.2.15. I can't find this bug listed on the sourceforge
>> bug list.
>Hmm. This *used* to happen on Linux (with slightly different
>symptoms; control-C would kill the interpreter, not hang it), but the
>bug got fixed. A couple of things to try: does control-C do what it
>should when you're not sitting at the ">>> " prompt? E.g. if you type
>>>> while 1:
>and whack control-C, what happens?
>The other thing is to try building without threads.
>The problem with Linux was a sigaction/signal mismatch - but I don't
>know a lot about signal handling and nothing at all about IRIX, so I
>can't say if I'd expect trouble here....
Strange.. readline has *never* worked right for me, on IRIX or Linux, on any
version of python (1.4, 1.5.2, 2.0), and any version of readline (3.0, 4.0,
4.1), if python is compiled with threads. IRIX (6.4, 6.5, 6.5.2) hangs, Linux
(2.0.36, 2.2.12, 2.2.17) exits.
I gave up trying to get it to work a long time ago, and compiled a seperate
python with no threads for when it's important.
I just tried your 'while 1: pass' thing, and the behaviour is the same there
More information about the Python-list