pip升级到7.0以后,在使用http镜像进行包安装及升级的时候往往会有如下提示:

Collecting beautifulsoup4
The repository located at mirrors.aliyun.com is not a trusted or secure host and is being ignored. If this repository is available via HTTPS it is recommended to use HTTPS instead, otherwise you may silence this warning and allow it anyways with ‘–trusted-host mirrors.aliyun.com’.
Could not find a version that satisfies the requirement beautifulsoup4 (from versions: )
No matching distribution found for beautifulsoup4

解决办法如下:

1.安装时加入–trusted-host mirrors.aliyun.com参数:

 
1
pip install beautifulsoup4 --trusted-host mirrors.aliyun.com

2.在pip.conf中加入trusted-host选项,该方法是一劳永逸

 
1
2
3
4
[global]
index-url = http://mirrors.aliyun.com/pypi/simple/
[install]
trusted-host=mirrors.aliyun.com

最新文章

  1. Online Judge(OJ)搭建(第一版)
  2. python-print
  3. mvc.net 的四种传值方式
  4. kali2 ssh
  5. 经典的单例模式c3p0来控制数据库连接池
  6. MOOTOOLS简单操作应用知识
  7. IOS拷贝文件到沙盒
  8. .NET MVC4 实训记录之四(Unit of work + Repository)
  9. 史上最全的css hack(ie6-9,firefox,chrome,opera,safari)
  10. CentOS 7 安装 JDK
  11. 老李分享:JVM调优
  12. 弹性盒模型 flex box
  13. hdu3081 Marriage Match II
  14. 60.Vue:将px转化为rem,适配移动端
  15. addEventListener() 和 removeEventListener()
  16. asp.net core2.1 bundleconfig.json合并压缩资源文件
  17. [学习笔记]JS计数器,闭包和localStorage
  18. 20180831xlVBA_WorkbooksCosolidate
  19. for练习.html
  20. Mysql 获取表属性

热门文章

  1. Linux环境下Redis安装配置步骤[转]
  2. 安装tensorflow出现问题的解法
  3. Xcode :Missing file warnings
  4. Android开发学习笔记-splash画面的显示
  5. 使用apache的poi实现导入导出excel
  6. myeclipse安装jad反编译插件
  7. javascript生成m位随机数
  8. js提取新浪邮箱的信用卡
  9. VS2010安装包制作全过程图解
  10. php 安装rabbitmq扩展无报错版