How do I repeat the last command? The usual keys: Up, Ctrl+Up, Alt-p don\'t work. They produce nonsensical characters.
(ve)[kakarukeys@localhost ve]$ python
This can happen when you run python script.py vs just python to enter the interactive shell, among other reasons for readline being disabled.
python script.py
python
Try:
import readline