Garbled lines and backspace keys in Python-5.8 Interactive Mode in CentOS 2.7.5
In CentOS 5.8 (x86_64), direction keys and backspace keys in Python-2.7.5 interactive mode are garbled.
After upgrading Python in CentOS to version 2.7.5, it is found that Python keys are garbled in interactive mode. It is found that the readline module is missing from the system. By default, only the readline module is installed in CentOS 5.8, but the readline-devel module is not installed.
# Install readline-devel
$ Yum install readline-devl
# Reinstall python
$./Configure
$ Sudo make install
This problem should have been solved. If the problem persists, try using the readline module that comes with Python:
# Configure
$./Configure
# Switch to the Modules directory and modify the Setup file
$ Cd Modules
$ Vi Setup
# Cancel # readline. c-lreadline-ltermcap line annotator
# Then reinstall python
$ Make install
-------------------------------------- Split line --------------------------------------
Install Python3.4 on CentOS source code
Python core programming version 2. (Wesley J. Chun). [Chinese version of hd pdf]
Python development technology details. (Zhou Wei, Zong Jie). [hd PDF scan version + book guide video + code]
Obtain Linux information using a Python script
Build a desktop algorithm transaction research environment using Python in Ubuntu
A Brief History of Python Development
Python details: click here
Python: click here
This article permanently updates the link address: