Selenium,解决Message: 'geckodriver' executable needs to be in PATH
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Selenium,解决Message: 'geckodriver' executable needs to be in PATH相关的知识,希望对你有一定的参考价值。
Windows系统解决办法如下:
Firefox:
1、下载geckodriver.exe:
下载地址:https://github.com/mozilla/geckodriver/releases
请根据系统版本选择下载;(如Windows 64位系统)
2、下载解压后将getckodriver.exe复制到浏览器安装目录,如:C:\\Program Files (x86)\\Mozilla Firefox,然后目录路径添加到环境变量path下;再把geckodriver复制到pythonan安装目录,如:C:\\Users\\Wuhl\\AppData\\Local\\Programs\\Python\\Python35
chrome:
1、下载chromedriver
驱动的下载地址如下:
http://chromedriver.storage.googleapis.com/index.html
chromedriver与chromed版本对应
2、下载解压后将chromedriver.exe复制到浏览器安装目录,如:C:\\Program Files (x86)\\Google\\Chrome\\Application(可能不需要这一步),然后目录路径添加到环境变量path下(可能不需要这一步);再把chromedriver.exe复制到pythonan安装目录,如:C:\\Users\\Wuhl\\AppData\\Local\\Programs\\Python\\Python35
以上是关于Selenium,解决Message: 'geckodriver' executable needs to be in PATH的主要内容,如果未能解决你的问题,请参考以下文章
selenium.common.exceptions.WebDriverException: Message: 'geckodriver' executable needs to be
bugRecord2selenium.common.exceptions.WebDriverException: Message: 'geckodriver' executable(代
python selenium模块使用出错-selenium.common.exceptions.WebDriverException: Message: 'geckodriver'
selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to b
selenium启动chrome出错处理:Message: 'chromedriver' executable needs to be in PATH
selenium.common.exceptions.JavascriptException: Message: javascript error: Cannot set property '