[IPython-dev] Console ipython - multi-line history editing
p.f.moore at gmail.com
Wed Oct 22 15:14:40 EDT 2014
On 21 October 2014 17:00, Paul Moore <p.f.moore at gmail.com> wrote:
> On 21 October 2014 16:45, Thomas Kluyver <takowl at gmail.com> wrote:
>> You remember right, it should work in the terminal too. However, it's
>> possible that pyreadline doesn't support that. It certainly works with gnu
>> readline on Linux.
> Oh, cool! I'll do some digging then and see if I can work out what's
> going on. Maybe you're right and it's a pyreadline issue.
Actually, it looks like it's deliberate in IPython. See
(back in 2011).
I'm not entirely sure how I change that config directly, so I hacked
the source. With TerminalInteractiveShell.multiline_history=True,
multi-line history works, but the display is corrupted. So it looks
like there is a pyreadline display issue at the root of this (i.e.,
it'd need multi-line display in pyreadline to work before it made
sense to default this to True).
Sadly, it'd probably take me a *lot* of work to work out how to fix
this myself :-(
PS How would I set TerminalInteractiveShell.multiline_history on the
IPython command line? I'd like to at least report this as a pyreadline
bug, and being able to describe how to reproduce it *without* saying
"hack IPython" would be nice :-)
More information about the IPython-dev