Better interactive shell for ActivePython

activepython blog hero
ActivePython users on Linux or MacOSX may have noted that the arrow keys do not work properly in the command-line Python shell. When you hit up-arrow in the shell, ActivePython gives you “^[[A“. This is because ActivePython does not include GNU readline due to licensing restrictions.

Fortunately, ActivePython comes with PyPM (Python Package Manager), using which you can install readline yourself. While you’re doing that, you might also want to try IPython, which provides tab completion and a number of other nifty features.
If you are using Linux or MacOSX, then all you need to do is type the following in Terminal:

$ pypm install readline
$ pypm install ipython

On Windows, in the command prompt window:

C:\> pypm install pyreadline
C:\> pypm install ipython

You’ll need ActivePython or above installed (3.x is not supported by PyPM yet). To learn about IPython, see Jeff Rush’s video demonstrations.

Recent Posts

Webinar - Walking Dead Past Python EOL
Walking Dead Past Python EOL

With Red Hat dropping Python 2 support, more organizations will be stuck maintaining zombie legacy apps. Stop racing against EOL dates and letting bad practices infect your new projects. Get current and stay current with the latest open source language versions.

Read More
Scroll to Top