In shells like the interactive python shell, you can usually use the arrow keys to move around in the current line or get previous commands (with arrow-up) etc.
But after I ssh into another machine and start
>>> import os
Looks like readline is not enabled. Check if PYTHONSTARTUP variable is defined, for me it points to /etc/pythonstart and that file is executed by the python process before going interactive, which setups readline/history handling.
Thanks to @chown here is the docs on this: http://docs.python.org/2/tutorial/interactive.html