selenium启动谷歌浏览器上报selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH.

同firefox一样,需要下载chromedriver 然后配置环境变量,chromedriver相对版本比较清晰,下载链接镜像:

http://npm.taobao.org/mirrors/chromedriver/

http://chromedriver.storage.googleapis.com/index.html

将chromedriver.exe拷贝到python的安装目录即可,因为python的安装目录已经添加了Path环境变量,所以无需再次添加

再运行一下pycharm,发现浏览器可以正常执行

问题解决链接:

https://blog.csdn.net/weixin_44335092/article/details/109054128

 

参考文章链接:

https://cloud.tencent.com/developer/article/1443818?from=article.detail.1653345

posted @ 2021-08-12 16:05  GalaxyStar  阅读(152)  评论(0编辑  收藏  举报