New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Segfault when pressing up arrow with no history #5260
Comments
Segfaults are very unlikely to be bugs in IPython, because it is pure Python code. In this case, I would look for a bug in readline. |
Thanks for the response. It looks like readline was updated to version 6.3-1 yesterday. I downgraded to 6.2 and everything is working. I'll report this bug to the readline developers. |
@minrk has just guessed that it might be an ABI version mismatch between readline and its Python bindings - if that is the case, then recompiling Python should fix it. |
I tried recompile python 3.3.4 and 3.4.5rc2 against readline 6.3 and the crash still exists. Here is Linux Arch bug report https://bugs.archlinux.org/task/39144 @takluyver you are experienced in python bindings so any help from you is welcome. |
Note that python interactive shell that also uses readline does not reproduce this crash. I can repro it only with ipython shell. |
I don't really know much about the Python readline bindings - I know that readline is what handles the history when you press up/down, and I know Python code can't cause segfaults except in very unusual circumstances. Given that @gsingh93 upgraded readline recently, it's an easy guess that that's responsible. But I have no experience of debugging C code. |
There is a discussion in readline maillist. The readline developer says that he cannot reproduce the problem and most likely Python does weird thing with initialization or with signal handler. There is no clear answer yet but we keep investigating. |
A patch (to readline) appears to be in the pipes for this: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=741555 |
I can confirm that switching from |
I'm running ipython 1.2.1 in Arch Linux. When I press the up key and there is no more available history, ipython segfaults. Here is how to duplicate it:
The text was updated successfully, but these errors were encountered: