美文网首页
在pycharm中安装selenium库

在pycharm中安装selenium库

作者: 分析师_8840 | 来源:发表于2021-09-06 23:54 被阅读0次

当要执行from selenium import webdriver时,突然提示pycharm中没有selenium库,所以这个库卡住了我两天,明天晚上没有搞出来,直到今天才搞出来!!!所以,我不得不记录一下解决过程

参考链接:https://blog.csdn.net/streamery/article/details/104821478

其实有好几个问题,就是说这个问题解决了,另一个问题右出来了,总的两说有3个:

问题一:安装selenium库报错:Non-zero exit code(1)

 pip要升级,在文件-设置-Project Interpreter中,选择右侧窗口中的pip,然后会出现它的现在version和 latest version, 如果要更新,则会出现一个向上的箭头,在最下面有一个向上的箭头,点击后就会更新。

问题二:提示selenium版本不对“pip selenium安装出错 Could not find a version that satisfies the requirement selenium (from versions: )”

这个时候,就是要选择selenium库安装窗口右下侧的 Specify version, 选中你电脑上目前的版本,比如说 3.141.0

问题三:报错“error loading package list:no protocal:pip install --index https:mirrors.ustc.edu.cn/pypi/web/simple”

这是因为在安装库前,不断在的在那里试错,最后把selenium库安装窗口右下侧的 Manage Repositories 里面的镜像网站搞乱了,最后参考以下链接才解决的

参考链接:https://blog.csdn.net/streamery/article/details/104821478

相关文章

网友评论

      本文标题:在pycharm中安装selenium库

      本文链接:https://www.haomeiwen.com/subject/msquwltx.html