Bug: Readline getting stuck on Linux and Solaris

Michael Hudson mwh21 at cam.ac.uk
Wed Dec 6 21:08:41 CET 2000


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:
...    pass
...

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....

Cheers,
M.

-- 
  This makes it possible to pass complex object hierarchies to 
  a C coder who thinks computer science has made no worthwhile
  advancements since the invention of the pointer.
                                       -- Gordon McMillan, 30 Jul 1998



More information about the Python-list mailing list