2

I recently found that my Selenium Java libraries were not working. Version 2.48.2 would open a Firefox window and then "stall" with no error within Netbeans nor Firefox itself before returning from new FirefoxDriver(). I figured that this version of Selenium might be broken so I found the latest Java libraries (Version 2.53.1) and have been trying to get them to work.

My issue now is almost the same but with two errors. The first is thrown by Netbeans when trying to execute new FirefoxDriver().

Exception in thread "AWT-EventQueue-0" org.openqa.selenium.remote.UnreachableBrowserException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure.
Build info: version: '2.53.1', revision: 'a36b8b1', time: '2016-06-30 17:32:46'
System info: host: 'MrComputer', ip: '192.168.0.101', os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.8.0_65'
Driver info: driver.version: FirefoxDriver
    at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:665)
...

The second is from Firefox itself. The window opens but instantly encounters the error.

Problem signature:
  Problem Event Name:   APPCRASH
  Application Name: firefox.exe
  Application Version:  47.0.0.5999
...

The code I am using is quite simple. Just the line

WebDriver driver = new FirefoxDriver();

I am by no means an extremely knowledgeable Selenium user so I am not sure what other information I could provide that might be of help.

EDIT: It seems that my Firefox version was not high enough to use the 2.53.1 Selenium libraries. My version of 47.0.0.5999 needed to be at least 47.0.1.

Prior to this, version 2.53.0 did need to make use of the MarionetteDriver as per this SO answer.

Unfortunately Selenium WebDriver 2.53.0 is not compatible with Firefox 47.0. The WebDriver component which handles Firefox browsers (FirefoxDriver) will be discontinued. As of version 3.0, Selenium WebDriver will have MarionetteDriver as the default running implementation for Firefox tests.

...

UPDATE

Selenium WebDriver 2.53.1 has been released on 30th June 2016. FirefoxDriver is working again with Firefox 47.0.1 as browser.

Community
  • 1
  • 1
KDecker
  • 6,928
  • 8
  • 40
  • 81
  • If your firefox verison `47` you need to use `MarionetteDriver`.. have a look https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver – Saurabh Gaur Jul 08 '16 at 06:00
  • Excuse me if this sounds snarky, but I cannot find a single mention on that page or the parent page of it that mentions that I must use `MarionetteDriver`, do you have any "proof" that I must use it over `FirefoxDriver`? – KDecker Jul 08 '16 at 13:51
  • I also take it you imported the correct firefox driver library? – scarecrow- Jul 08 '16 at 14:04
  • I might have not, could you explain what you mean by Firefox driver library? I assume this is the Selenium jar file? (I don't have the exact name in front of me) Something like `selenium-java-2-53-1.jar`? Along with the server jar file `selenium-server-java-2-53-1.jar`? – KDecker Jul 08 '16 at 14:07
  • Have you tried to find out the solution on google regarding this... there are many exampls that proofs it to use `MarionetteDriver`... even i`m using also..:) – Saurabh Gaur Jul 08 '16 at 14:13
  • I always go to google first. // Could you provide a link to the proof, I cant seem to find anything on it.// EDIT: Ahh I found something http://stackoverflow.com/questions/37693106/selenium-2-53-not-working-on-firefox-47 – KDecker Jul 08 '16 at 15:03
  • At the end of the first answer in the link I posted there is the update "Selenium WebDriver 2.53.1 has been released on 30th June 2016. FirefoxDriver is working again with Firefox 47.0.1 as browser." // From what I can tell `MarionetteDriver` is not needed at this point. – KDecker Jul 08 '16 at 15:07
  • So from what I can now gather, from the link I posted in the comment above and my error message in the OP. I need to upgrade my FF version from `47.0.0.5999` to at least `47.0.1`. I will try this when I have time later and report back. – KDecker Jul 08 '16 at 15:13

1 Answers1

2

For Selenium 2.53.1 the Firefox version needs to be at least 47.0.1. Updating my Firefox did the trick.

EDIT: It also seems that version 47.+ was not released to the Ubuntu archives for a few weeks after the Windows version.

KDecker
  • 6,928
  • 8
  • 40
  • 81