Webdriver:Unsupported Marionette protocol version 2, required 3

升级到firefox到47以上版本即可

坑人的Mozilla不能起个我们熟识的名字吗? 先是webdriver.gecko.driver后是Marionette protocol。

 
1、WebDriverException: Message: 'geckodriver' executable needs to be in PATH.
下载firefox驱动geckodriver可以放到python安装目录C:\Python27,http://docs.seleniumhq.org/download/
 
2、WebDriverException: Message: Unsupported Marionette protocol version 2, required 3
To resolve this issue you need to upgrade your Mozilla Firefox >= v47 as well.
 
复制代码

from selenium import webdriver
import time

browser = webdriver.Firefox()
browser.get("http://www.baidu.com")
browser.find_element_by_id("kw").send_keys("selenium")
browser.find_element_by_id("su").click()
time.sleep(5)
browser.quit()

复制代码

 

Marionette Protocol - Mozilla | MDN
https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/Protocol

The Marionette remote control protocol lets out-of-process programs to communicate with Gecko.

 

参考:

java - "org.openqa.selenium.WebDriverException: Unsupported Marionette protocol version 2" error coming while running my Selenium Script with Gecko Driver - Stack Overflow
http://stackoverflow.com/questions/39729930/org-openqa-selenium-webdriverexception-unsupported-marionette-protocol-version

selenuim +python环境配置遇到的诸多问题 - 荒荒9468 - 博客园
http://www.cnblogs.com/fangfangs/p/f0000000f.html

posted @   船长博客  阅读(1333)  评论(0编辑  收藏  举报
编辑推荐:
· AI与.NET技术实操系列(二):开始使用ML.NET
· 记一次.NET内存居高不下排查解决与启示
· 探究高空视频全景AR技术的实现原理
· 理解Rust引用及其生命周期标识(上)
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
阅读排行:
· DeepSeek 开源周回顾「GitHub 热点速览」
· 物流快递公司核心技术能力-地址解析分单基础技术分享
· .NET 10首个预览版发布:重大改进与新特性概览!
· AI与.NET技术实操系列(二):开始使用ML.NET
· .NET10 - 预览版1新功能体验(一)
永远相信美好的事情即将发生!
点击右上角即可分享
微信分享提示