Léo Henry
Léo Henry

Reputation: 137

Cannot Open firefox on rsDriver on RSelenium Mac

I have a problem oppenning firefox with RSelenium on R on my mac.

When I put:

remDr <- rsDriver(browser = "firefox", port=4443L)$client

I get this answer

checking Selenium Server versions:
BEGIN: PREDOWNLOAD
BEGIN: DOWNLOAD
BEGIN: POSTDOWNLOAD
checking chromedriver versions:
BEGIN: PREDOWNLOAD
BEGIN: DOWNLOAD
BEGIN: POSTDOWNLOAD
checking geckodriver versions:
BEGIN: PREDOWNLOAD
BEGIN: DOWNLOAD
BEGIN: POSTDOWNLOAD
checking phantomjs versions:
BEGIN: PREDOWNLOAD
BEGIN: DOWNLOAD
BEGIN: POSTDOWNLOAD
[1] "Connecting to remote server"
Could not open firefox browser.
Client error message:
Undefined error in httr call. httr output: Failed to connect to localhost port 4443: Connection refused
Check server log for further details.
Warning message:
In rsDriver(browser = "firefox", port = 4443L) :
  Could not determine server status.

Firefox page does not open.

Is there anyone knowing what might be the problem?

Upvotes: 1

Views: 952

Answers (2)

schroederadrian
schroederadrian

Reputation: 59

Above didn't work for me and this problem drove me crazy for 2 days :( Here's finally what worked for me:

  1. Make sure you install the above Java Development kit and the Firefox browser
  2. Install geckodriver as described here: https://medium.com/dropout-analytics/selenium-and-geckodriver-on-mac-b411dbfe61bc
  3. In R, uninstall RSelenium. Make sure to install the following packages in exactly this order:
  4. netstat
  5. wdman
  6. rvest
  7. If you're not sure you installed in the correct order, re-install all of them in order. It will save your sanity
  8. Only then (!!) install RSelenium
  9. Follow the remainder in this guide: https://rpubs.com/grahamplace/rseleniumonmac
  10. When prompted in above guide to install the standalone Selenium, go to http://selenium-release.storage.googleapis.com/index.html
  11. Send me a donation equal to the amount you would pay a shrink for 2 days worth of therapy. Just kidding.

After this, you should be set.

Upvotes: 0

L&#233;o Henry
L&#233;o Henry

Reputation: 137

For everyone who might be in a similar situation, I finally managed to solve this issue by installing Java SE Development Kit 14 on my Mac.

I did not close the post because I thought it might help someone else.

Upvotes: 1

Related Questions