0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Jetsonのpyenv仮想環境でタブ補完が効かなくなったら

0
Last updated at Posted at 2021-03-09

JetsonでPython仮想環境を構築したときにタブ補完が効かなくなった時の対処の覚書です。

タブ補完が効かないのはreadlineモジュールが読み込めなくなっているためです。

とりあえずの対処は、システムPythonのreadlineモジュールをpyenv環境にリンクしてあげます。

pyenv環境は$HOME/.pyenv、Pythonバージョンは3.6.11の例です。

ln -s /usr/lib/python3.6/lib-dynload/readline.cpython-36m-aarch64-linux-gnu.so $HOME/.pyenv/versions/3.6.11/lib/python3.6/lib-dynload/readline.cpython-36m-aarch64-linux-gnu.so

根本解決には
pyenv仮想環境の再インストールが必要です。

必要なパッケージをインストール
実は他にも取り込めていないモジュールがあったようなのでまとめて更新。

sudo apt install -y libbz2-dev libreadline-dev libsqlite3-dev
pyenv uninstall 3.6.11
pyenv install 3.6.11
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?