Python中安装库时报错:WARNING: Running pip as the ‘root‘ user can re
未知
2024-01-09 14:44:46
0
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv




1、通过find命令查找pip安装位置:
 

find / -name pip-*
 

2、使用cd命令跳转到pip安装位置
 

cd /usr/bin
 

3、建立虚拟环境
 

python3 -m venv tutorial-env
 

4、激活和使用虚拟环境
 
Linux下:

source tutorial-env/bin/activate
 

此处命令执行是没有回显的

相关内容

python pip安装r...
python pip安装requests报错一片红解决方法
2024-07-29 10:12:25
解决You are usi...
You are using pip version 21.3.1,...
2024-01-09 14:50:45
Python中安装库时报错...
WARNING: Running pip as the 'root...
2024-01-09 14:44:46
pip3 command ...
安装pip3很简单。您只需要运行以下命令:
2023-12-20 11:12:24
python uiauto...
问题描述: 打开C:\Users\Administrator\Ap...
2021-09-22 10:04:44
python cannot...
appium_python_client已经安装,selenium...
2021-09-22 09:15:02

热门资讯

python pip安装req... python pip安装requests报错一片红解决方法
python uiautoma... 问题描述: 打开C:\Users\Administrator\AppData\Local\Andro...
解决You are using... You are using pip version 21.3.1, however version ...
查询pthon chromed... 查询pthon chromedrive是否匹配,确认当前的Google Chrome版本号与chro...
Python中安装库时报错:W... WARNING: Running pip as the 'root' user can result...
python cannot i... appium_python_client已经安装,selenium也安装了,报错:cannot im...