Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ruby selenium webdriver unable to find Mozilla geckodriver

I have geckodriver installed in my development directory

ls | grep geckodriver
geckodriver
geckodriver-v0.11.1-linux64.tar.gz

I also exported to the $PATH variable

export PATH=$PATH:~/Development/geckodriver

But when I attempt to initialize an instance of the webdriver on rails console of my project I get this

driver = Selenium::WebDriver.for :firefox

Selenium::WebDriver::Error::WebDriverError: Unable to find Mozilla geckodriver. Please download the server from https://github.com/mozilla/geckodriver/releases and place it somewhere on your PATH. More info at https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver What's the issue here.

like image 640
user2968505 Avatar asked Dec 24 '16 05:12

user2968505


1 Answers

You have selenium-webdriver-3.0.0.beta3.1 which is only for Firefox 48 and later (and not yet properly working). Fallback to selenium-webdriver version 2.53.4 and try again.

And also try this..

  • In the terminal change directory path to the directory where gem was installed
  • Run gem uninstall selenium-webdriver
  • Run gem install selenium-webdriver -v 2.53.4
like image 147
Karthick Nagarajan Avatar answered Sep 19 '22 15:09

Karthick Nagarajan