导包的时候提示: raise WebDriverException(
selenium.common.exceptions.WebDriverException: Message: ‘chromedriver’ executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home
报错
selenium.common.exceptions.WebDriverException: Message: ‘chromedriver’ executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home
原因
Chromedriver没有加入到path。
解决办法:将Chromedriver加入到path。
步骤1. 下载chromedriver
chromedriver的下载地址: http://chromedriver.storage.googleapis.com/index.html
这里要注意:chromedriver的版本有很多,一定要下载与你电脑上chrome浏览器版本相对应的版本。
步骤2. 将chromedriver.exe复制到项目目录
重启编译器,再次运行发现未报错,说明配置已生效。