G Lockwood
G Lockwood

Reputation: 35

RSelenium, Can't start server

I'm trying to use RSelenium for web-scraping purposes behind a login and I can't get the server to run.

Current result:

library(RSelenium)
startServer()
remDr <- remoteDriver(port = 4444,
                      browserName = "firefox") 
remDr$open()
# [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

I've tried running the server myself by downloading and trying to open it (nothing happens).

Upvotes: 2

Views: 1096

Answers (3)

Geron
Geron

Reputation: 85

Try below.

rD <- rsDriver(port=4444L,browser="firefox")
mybrowser <- remoteDriver(browserName = "firefox") 
mybrowser$open() 

RSelenium has problems to establish serwer at the begginig on respective port. Subsequently we are telling which driver should be used.

Upvotes: 0

Pat M
Pat M

Reputation: 44

This was a tough one and stopped me for a couple of days when I could search on it. In the end I uninstalled Firefox and installed version 37.0 while also disabling the update service. That fixed it for me and RSelenium works fine again.

Upvotes: 1

Mohammad
Mohammad

Reputation: 1098

Run the following code first then it should work:

RSelenium::checkForServer()

This line of code installs the selenium server which you need for running RSelenium commands.

Upvotes: 0

Related Questions