- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In 2.7.10 the arrow keys work normally
In 2.7.11 left gives ^[[D
In 2.7.13 left gives ^[[D
Tried various terminal setups in putty and from a nomachine session and from an xterm. Host is centos7. all 3 version are installed on the same machine.
Up arrow gives ^[[A which makes it annoying to retype a whole line for a simple typo.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Arrow keys require the readline library, which is GPL. The simplest solution is to use python from anaconda + intel libraries for everything else:
conda remove --force python
conda
install
-c anaconda python
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Arrow keys require the readline library, which is GPL. The simplest solution is to use python from anaconda + intel libraries for everything else:
conda remove --force python
conda
install
-c anaconda python
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
kgore4,
In case you move to IPython, make sure you read this post because readline is also GPL. Just in case...
https://software.intel.com/en-us/forums/intel-distribution-for-python/topic/704018
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
A workaround to resolve the arrow key issue (tested under linux sh shell) is to start python preceded by 'rlwrap' like so:
$ rlwrap python
This can be written as an alias in the ".bashrc" file
Sergio
Enhance your #MachineLearning and #BigData skills via #Python #SciPy
1) https://www.packtpub.com/big-data-and-business-intelligence/numerical-and-scientific-computing-scipy-video
2) https://www.packtpub.com/big-data-and-business-intelligence/learning-scipy-numerical-and-scientific-computing-second-edition
3) FREE (beginner) PYTHON book in Spanish:
https://www.researchgate.net/publication/301293668_Aprendiendo_a_Programar_en_Python_con_mi_Computador_Primeros_pasos_rumbo_a_computos_de_gran_escala_en_las_Ciencias_e_Ingenierias
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Worked for me, simpler than messing with conda
sergio r. wrote:
A workaround to resolve the arrow key issue (tested under linux sh shell) is to start python preceded by 'rlwrap' like so:
$ rlwrap pythonThis can be written as an alias in the ".bashrc" file
Sergio
Enhance your #MachineLearning and #BigData skills via #Python #SciPy
1) https://www.packtpub.com/big-data-and-business-intelligence/numerical-an...
2) https://www.packtpub.com/big-data-and-business-intelligence/learning-scipy-numerical-and-scientific-computing-second-edition
3) FREE (beginner) PYTHON book in Spanish:
https://www.researchgate.net/publication/301293668_Aprendiendo_a_Programar_en_Python_con_mi_Computador_Primeros_pasos_rumbo_a_computos_de_gran_escala_en_las_Ciencias_e_Ingenierias
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Try
pip install gnureadline
instead just readline
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Update for this older thread:
Our Linux python 3 distribution now includes pyeditline, a python package that implements much of the readline functionality on top of the editline library. You should see normal command-line editing features in python 3 on linux. We don't plan on adding it to our python 2.7 distribution at this time because pyeditline does not support python 2.
You can install it into an existing python 3 environment using "conda install pyeditline -c intel".
Todd
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page