[IPython-user] Prefix/partial history scrolling

Robert Kern robert.kern@gmail....
Mon Jan 5 15:07:14 CST 2009

Max Bane wrote:
> Heyo,
> I just installed IPython 0.9.1 on an OSX machine, and was disappointed
> to find that partial history scrolling no longer seems to happen.
> Suppose I've run the following two commands immediately after starting
> IPython:
> In [1]: print 'hello'
> hello
> In [2]: 1 + 2 + 3
> Out[2]: 6
> In [3]:
> At this point if I hit the up arrow, I end up with the previous line,
> as expected:
> In [3]: 1 + 2 + 3
> But if I type a prefix of the first line and hit the up arrow, I
> expect to get the first line, but instead I end up with the second
> line, as if I had just hit the up arrow without any prefix:
> In [3]: pri
> <up>
> In [3]: 1 + 2 + 3
> <should be: In [3]: print 'hello'>
> What am I missing? On my other machines I don't recall ever having to
> set an option to enable prefix history scrolling. I searched this list
> for all 7 non-empty subsets of the terms ['partial', 'prefix',
> 'history'] but found nothing.

My guess is that your readline module is linked against the fake libreadline 
library that Apple installed into /usr/lib/. It's actually Editline, not GNU 
Readline, so it might have a slightly different feature set or need extra 
configuration. I use the Python binaries from www.python.org and 
www.enthought.com (disclosure: I work at Enthought), and I get the expected 
partial prefix scrolling.

Robert Kern

"I have come to believe that the whole world is an enigma, a harmless enigma
  that is made terrible by our own mad attempt to interpret it as though it had
  an underlying truth."
   -- Umberto Eco

More information about the IPython-user mailing list