Fixing the up button in Python shell history

In case your python/ipython shell doesn’t have a working history, e.g. pressing ↑ only prints some nonsensical ^[[A, then you are missing either the readline or ncurses library.

Python shell where up doesn't work

Ipython is more descriptive that something is wrong, but if you’re in the habit of mostly using python as a quick calculator, you might never notice:

iPython shell where up doesn't work

If you’re using Miniconda then just do:

conda install ncurses readline

And ↑ should work:

iPython with working up