Readline functionality on windows with python 2.7

前端 未结 2 1903
囚心锁ツ
囚心锁ツ 2020-12-15 04:02

I need to import the readline functionality in a program written in python. I am currently using version 2.7 and the 3rd party packages I have seen only work up to version 2

2条回答
  •  我在风中等你
    2020-12-15 04:25

    Unfortunately, in 2019, pyreadline isn't really developed anymore.

    It's far from a "drop-in" replacement, but you could look into Python Prompt Toolkit. It provides tab-completion and then some on just about every platform there is. If you're still using Python 2, you have five months to update but the Prompt Toolkit does appear to support Python 2 with from __future__ import unicode_literals.

提交回复
热议问题