[英]Getting error “/usr/bin/python3.9: bad interpreter: No such file or directory” after installing pip in ubuntu 16.04
I installed python3.9 in ubuntu and also make it default which creates some problems.我在 ubuntu 中安装了 python3.9 并将其设为默认值,这会产生一些问题。 So I again make python 3.5 as default and removed python 3.9.所以我再次将 python 3.5 作为默认值并删除了 python 3.9。
Then I tried to install pip by using command:然后我尝试使用以下命令安装 pip:
sudo apt-get install python3-pip
and it installed successfully but when I ran:它安装成功,但是当我运行时:
pip3 --version
it gives me this error:它给了我这个错误:
/usr/bin/python3.9: bad interpreter: No such file or directory
I don't know why I removed python 3.9 completely with all its dependencies then why pip is not installing properly?我不知道为什么我完全删除了 python 3.9 及其所有依赖项,那么为什么 pip 没有正确安装?
Please help me out here i'm really stuck.请帮助我在这里我真的被困住了。
这个答案可能会有所帮助,您可以将pip
作为模块运行,尝试python3 -m pip [commands]
看看它是否有效。
Try running:尝试运行:
pip --version
It might work.它可能会起作用。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.