在CentOS上遇到pip包管理器问题

问题描述 投票:0回答:1

想在CentOS上使用pip安装python包(特别是psycopg2)。无法理解我的python3安装有什么问题,pipnot认可:

$pip install psycopg2
-bash: /usr/bin/pip: /usr/bin/python: bad interpreter: No such file or directory

$pip install --upgrade pip
-bash: /usr/bin/pip: /usr/bin/python: bad interpreter: No such file or directory

$ python3.7 -V
Python 3.7.2

$which python3.7
/usr/local/bin/python3.7

知道为什么pip不起作用?

python python-3.x pip centos psycopg2
1个回答
2
投票

您可以通过运行:python3.7 -m pip install psycopg2从首选的Python解释器调用pip模块

© www.soinside.com 2019 - 2024. All rights reserved.