
私の suse-linux マシン (SUSE Linux Enterprise Server 12 SP1) には Python 2.9 が入っています。これを Python 3.8.8 にアップグレードしました。
pipをインストールしようとすると
zypper install python3-pip
python3-pip が見つからないと表示されます。python3 が正しくインストールされていないのではないかと思います。
を実行するとpython3.8 -m test
、次のエラーが発生します:
AttributeError: module 'posix' has no attribute '_all_'
During handling above exception, another exception occured:
SystemError: <built-in function dir> returned NULL without setting an error.
Python 3.8.8 のインストール方法は次のとおりです。次のコマンドを root として実行しました。
wget https://www.python.org/ftp/python/3.8.8/Python-3.8.8.tgz
tar -xvzf Python-3.8.8.tgz
cd Python-3.8.8
./configure
make
make install
export PATH=/usr/local/bin:$PATH
Stack Overflow でかなりの数の質問を読みましたが、どれもあまり役に立ちませんでした。
誰かこれを直すのを手伝ってくれませんか?
答え1
Anaconda をインストールすると問題は解決しました。