最新版本的RSelenium和Firefox

最新版本的RSelenium和Firefox,r,selenium,firefox,rselenium,R,Selenium,Firefox,Rselenium,当我试图打开RSelenium时,我收到了这个错误 [1] "Connecting to remote server" Error: Summary: UnknownError Detail: An unknown server-side error occurred while processing the command. class: org.openqa.selenium.firefox.NotConnectedException 我拥有的Firefox版本是

当我试图打开RSelenium时,我收到了这个错误

[1] "Connecting to remote server"
Error:   Summary: UnknownError
     Detail: An unknown server-side error occurred while processing the command.
     class: org.openqa.selenium.firefox.NotConnectedException
我拥有的Firefox版本是

Firefox version: 480b10
据我所知,我试图更新服务器版本

library("RSelenium")
startServer()
unlink(system.file("bin", package = "RSelenium"), recursive = T)
checkForServer(update = TRUE)
remDr <- remoteDriver()
Sys.sleep(5)
remDr$open()
Sys.sleep(5)
library(“RSelenium”)
startServer()
取消链接(system.file(“bin”,package=“RSelenium”),recursive=T)
checkForServer(更新=TRUE)

remDr在Firefox48上运行Selenium的Firefox需要gecko驱动程序/木偶

如果您有Firefox 48,您可以按如下方式运行gecko驱动程序:

参考指南

  • 从下载相关的gecko驱动程序
  • 在启动二进制文件时,将其添加到路径或参考位置(见下文)

  • 如果我们使用Firefox 46版本,问题就解决了。如果您使用Firefox 48,您将需要gecko驱动程序。请参阅,谢谢。这似乎合乎逻辑,但当我去测试你的答案时,我在
    RSelenium::checkForServer(beta=TRUE):unused argument(beta=TRUE)
    @Jake中收到了这个错误。你需要安装
    RSelenium
    的开发版本<代码>开发工具::安装github(“ropensci/Rselenium”)
    。或者,您可以手动启动服务器。我已对此添加了说明。
    # get beta selenium standalone
    
    RSelenium::checkForServer(beta = TRUE)
    # assume gecko driver is not in our path (assume windows and we downloaded to docs folder)
    # if the driver is in your PATH the javaargs call is not needed
    selServ <- RSelenium::startServer(javaargs = c("-Dwebdriver.gecko.driver=\"C:/Users/john/Documents/geckodriver.exe\""))
    remDr <- remoteDriver(extraCapabilities = list(marionette = TRUE))
    remDr$open()
    ....
    ....
    remDr$close()
    selServ$stop()  
    
    java -Dwebdriver.gecko.driver=C:/Users/john/Documents/geckodriver.exe -jar selenium-server-standalone-3.0.0-beta2.jar