(Linux ) WebDriverException: Message: 'chromedriver' executable needs to be in PATH. Please see...

使用 selenium 爬虫,遇到的一个webdriver的问题.

WebDriverException: Message: 'chromedriver' executable needs to be in PATH. Please see...

查阅了很多资料,发现是就是路径的问题.

从官网下载 和你浏览器版本对应的webdriver版本.

下载地址: 

https://sites.google.com/a/chromium.org/chromedriver/home

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

两个都可以.

下载完后是一个压缩包,解压得到webdriver 文件.

然后把这个文件,放在 /usr/local/bin  下就可以了 (我的系统是 Fedora 28)

扫描二维码关注公众号,回复: 3321938 查看本文章

命令:  

sudo mv webdriver /usr/local/bin

好了 搞定,可以正常驱动chrome

猜你喜欢

转载自blog.csdn.net/rs_hao/article/details/82811665