通过 pip 安装软件时提示 0.1.36ubuntu1,0.23ubuntu1 is an invalid version 的完美解决方案。

通过 pip 安装软件时提示 0.1.36ubuntu1,0.23ubuntu1 is an invalid version and will not be supported in a future release的完美解决方案。

实验测试通过的操作系统环境:

Ubuntu Linux 20.04 LTS
系统内核:Linux ubuntu 5.15.0-46

实验场景错误提示:

root@yark-Ai:~/mytools/flashlight/docs# pip install -r requirements.txt
/usr/local/lib/python3.8/dist-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: 
0.1.36ubuntu1 is an invalid version and will not be supported in a future release
  warnings.warn(
/usr/local/lib/python3.8/dist-packages/pkg_resources/__init__.py:123:
 PkgResourcesDeprecationWarning: 0.23ubuntu1 is an invalid version and will not be supported in a future release

错误提示分析:

错误提示的如下: 0.1.36ubuntu1,0.23ubuntu1 is an invalid version and will not be supported in a future release
意思是: 0.1.36ubuntu1,0.23ubuntu1 是无效的版本,在新的pip发布版本中將不再提供技术支持。
原因根源是你的python pip版本较低,无法适应新的开发环境
完美解决方案是把现有pip和python 卸载重新安装新的pip版本或者直接升级pip

直接升级最新版pip

看你的python 版本 如提示python命令不存在你可以改为python3替代

python -m pip install --upgrade pip

如果以上升級或重新安裝新版本之后您再用pip 安装软件时不再出现类似错误,恭喜您!,您已经彻底解决了隐患问题!

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值