Could not find a version that satisfies the requirement lxml解决方法

今天ytkah在安装lxml时提示错误ERROR: Could not find a version that satisfies the requirement lxml (from versions: none),ERROR: No matching distribution found for lxml,升级一下pip试试

python -m pip install --upgrade pip

  再次安装lxml还是错误,考虑到是网络不稳定的问题,这时我们用国内的镜像源来加速

pip install 包名-i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com

  --trusted-host pypi.douban.com 这是为了获得ssl证书的认证

执行成功!

不过每次这样手动输入会比较麻烦,建议每次换系统时先换成国内的镜像源,具体配置请参考https://blog.csdn.net/u012592062/article/details/51966649

 

posted @ 2020-02-19 17:41  ytkah  阅读(12583)  评论(1编辑  收藏  举报
网址导航 gg N / G Sitemap

部分内容来源于网络,如有版权问题请联系删除