selenium icon indicating copy to clipboard operation
selenium copied to clipboard

Firefox Developer Edition (47.0a2) crashes using Java Selenium 2.53.0 (and 2.52.0, 2.48.2)

Open javiermorante opened this issue 10 years ago • 7 comments

Meta -

OS: Ubuntu 14.04 LTS Selenium Version: 2.53.0, 2.52.0, 2.48.2 Browser: Firefox Browser Version: Firefox Developer Edition (47.0a2)

Expected Behavior

Execute Java selenium test using the Firefox Developer Edition (47.0a2).

I am using the following code to start the driver:

driver = new FirefoxDriver(new FirefoxBinary(new File(firefoxBin)), 
                        new FirefoxProfile());

Where "firefoxBin" is an String with the full path of Firefox binary file.

Actual Behavior -

The Firefox process dies after starting up. The Java selenium process returns a timeout error.

I have reviewed the Java code of Selenium and I have tried to run the Firefox process manually using the same options. I have confirmed that the problem is not caused by the "-foreground" or the environment options, the issue appears when the Selenium extensions are deployed in the profile.

Unfortunately the Firefox process dies without returning any error.

I have tried with multiple versions of Selenium (2.53.0, 2.52.0 or 2.48.2), the issue seems to be the same with all of them.

Steps to reproduce -

Just try to run a Java selenium script with Selenium 2.53 and Firefox Developer Edition (47.0a2)

This is the output of my script:

org.openqa.selenium.firefox.NotConnectedException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. Firefox console output:
    Updating database with changes to installed add-ons
1458659376845   addons.xpi-utils    DEBUG   Updating add-on states
1458659376846   addons.xpi-utils    DEBUG   Writing add-ons list
1458659376847   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376848   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.0
1458659376848   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376848   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.0
1458659376850   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376850   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.1.12
1458659376873   addons.manager  DEBUG   Registering shutdown blocker for XPIProvider
1458659376873   addons.manager  DEBUG   Provider finished startup: XPIProvider
1458659376873   addons.manager  DEBUG   Starting provider: LightweightThemeManager
1458659376873   addons.manager  DEBUG   Registering shutdown blocker for LightweightThemeManager
1458659376874   addons.manager  DEBUG   Provider finished startup: LightweightThemeManager
1458659376874   addons.manager  DEBUG   Starting provider: GMPProvider
1458659376880   addons.manager  DEBUG   Registering shutdown blocker for GMPProvider
1458659376881   addons.manager  DEBUG   Provider finished startup: GMPProvider
1458659376881   addons.manager  DEBUG   Starting provider: PluginProvider
1458659376881   addons.manager  DEBUG   Registering shutdown blocker for PluginProvider
1458659376881   addons.manager  DEBUG   Provider finished startup: PluginProvider
1458659376882   addons.manager  DEBUG   Completed startup sequence

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message
1458659378322   addons.manager  DEBUG   Starting provider: <unnamed-provider>
1458659378322   addons.manager  DEBUG   Registering shutdown blocker for <unnamed-provider>
1458659378323   addons.manager  DEBUG   Provider finished startup: <unnamed-provider>
1458659378641   DeferredSave.extensions.json    DEBUG   Write succeeded
1458659378642   addons.xpi-utils    DEBUG   XPI Database saved, setting schema version preference to 17
1458659378642   DeferredSave.extensions.json    DEBUG   Starting timer
1458659378667   DeferredSave.extensions.json    DEBUG   Starting write
1458659378677   addons.repository   DEBUG   No addons.json found.
1458659378678   DeferredSave.addons.json    DEBUG   Save changes
1458659378684   DeferredSave.addons.json    DEBUG   Starting timer
1458659378730   addons.manager  DEBUG   Starting provider: PreviousExperimentProvider
1458659378730   addons.manager  DEBUG   Registering shutdown blocker for PreviousExperimentProvider
1458659378731   addons.manager  DEBUG   Provider finished startup: PreviousExperimentProvider
1458659378742   DeferredSave.addons.json    DEBUG   Starting write
1458659378755   DeferredSave.extensions.json    DEBUG   Write succeeded

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message
1458659378851   DeferredSave.addons.json    DEBUG   Write succeeded

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

    at org.openqa.selenium.firefox.internal.NewProfileExtensionConnection.start(NewProfileExtensionConnection.java:112)
    at org.openqa.selenium.firefox.FirefoxDriver.startClient(FirefoxDriver.java:271)
    at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:119)
    at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:218)
    at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:211)
    at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:207)
    at com.smartbear.tests.examples.SimpleWebTest.init(SimpleWebTest.java:158)
    at com.smartbear.tests.examples.SimpleWebTest.<init>(SimpleWebTest.java:130)
    at com.smartbear.tests.examples.SimpleWebTest$1.run(SimpleWebTest.java:82)
    at java.lang.Thread.run(Thread.java:745)
Unexpected error at thread Thread-1: org.openqa.selenium.WebDriverException: Failed to connect to binary FirefoxBinary(/opt/firefox_dev_jmb/firefox) on port 7055; process output follows:
    Updating database with changes to installed add-ons
1458659376845   addons.xpi-utils    DEBUG   Updating add-on states
1458659376846   addons.xpi-utils    DEBUG   Writing add-ons list
1458659376847   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376848   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.0
1458659376848   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376848   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.0
1458659376850   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376850   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.1.12
1458659376873   addons.manager  DEBUG   Registering shutdown blocker for XPIProvider
1458659376873   addons.manager  DEBUG   Provider finished startup: XPIProvider
1458659376873   addons.manager  DEBUG   Starting provider: LightweightThemeManager
1458659376873   addons.manager  DEBUG   Registering shutdown blocker for LightweightThemeManager
1458659376874   addons.manager  DEBUG   Provider finished startup: LightweightThemeManager
1458659376874   addons.manager  DEBUG   Starting provider: GMPProvider
1458659376880   addons.manager  DEBUG   Registering shutdown blocker for GMPProvider
1458659376881   addons.manager  DEBUG   Provider finished startup: GMPProvider
1458659376881   addons.manager  DEBUG   Starting provider: PluginProvider
1458659376881   addons.manager  DEBUG   Registering shutdown blocker for PluginProvider
1458659376881   addons.manager  DEBUG   Provider finished startup: PluginProvider
1458659376882   addons.manager  DEBUG   Completed startup sequence

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message
1458659378322   addons.manager  DEBUG   Starting provider: <unnamed-provider>
1458659378322   addons.manager  DEBUG   Registering shutdown blocker for <unnamed-provider>
1458659378323   addons.manager  DEBUG   Provider finished startup: <unnamed-provider>
1458659378641   DeferredSave.extensions.json    DEBUG   Write succeeded
1458659378642   addons.xpi-utils    DEBUG   XPI Database saved, setting schema version preference to 17
1458659378642   DeferredSave.extensions.json    DEBUG   Starting timer
1458659378667   DeferredSave.extensions.json    DEBUG   Starting write
1458659378677   addons.repository   DEBUG   No addons.json found.
1458659378678   DeferredSave.addons.json    DEBUG   Save changes
1458659378684   DeferredSave.addons.json    DEBUG   Starting timer
1458659378730   addons.manager  DEBUG   Starting provider: PreviousExperimentProvider
1458659378730   addons.manager  DEBUG   Registering shutdown blocker for PreviousExperimentProvider
1458659378731   addons.manager  DEBUG   Provider finished startup: PreviousExperimentProvider
1458659378742   DeferredSave.addons.json    DEBUG   Starting write
1458659378755   DeferredSave.extensions.json    DEBUG   Write succeeded

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message
1458659378851   DeferredSave.addons.json    DEBUG   Write succeeded

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: host: 'selenium', ip: '127.0.0.1', os.name: 'Linux', os.arch: 'amd64', os.version: '3.13.0-59-generic', java.version: '1.8.0_72'
Driver info: driver.version: FirefoxDriver
org.openqa.selenium.WebDriverException: Failed to connect to binary FirefoxBinary(/opt/firefox_dev_jmb/firefox) on port 7055; process output follows:
    Updating database with changes to installed add-ons
1458659376845   addons.xpi-utils    DEBUG   Updating add-on states
1458659376846   addons.xpi-utils    DEBUG   Writing add-ons list
1458659376847   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376848   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.0
1458659376848   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376848   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.0
1458659376850   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376850   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.1.12
1458659376873   addons.manager  DEBUG   Registering shutdown blocker for XPIProvider
1458659376873   addons.manager  DEBUG   Provider finished startup: XPIProvider
1458659376873   addons.manager  DEBUG   Starting provider: LightweightThemeManager
1458659376873   addons.manager  DEBUG   Registering shutdown blocker for LightweightThemeManager
1458659376874   addons.manager  DEBUG   Provider finished startup: LightweightThemeManager
1458659376874   addons.manager  DEBUG   Starting provider: GMPProvider
1458659376880   addons.manager  DEBUG   Registering shutdown blocker for GMPProvider
1458659376881   addons.manager  DEBUG   Provider finished startup: GMPProvider
1458659376881   addons.manager  DEBUG   Starting provider: PluginProvider
1458659376881   addons.manager  DEBUG   Registering shutdown blocker for PluginProvider
1458659376881   addons.manager  DEBUG   Provider finished startup: PluginProvider
1458659376882   addons.manager  DEBUG   Completed startup sequence

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message
1458659378322   addons.manager  DEBUG   Starting provider: <unnamed-provider>
1458659378322   addons.manager  DEBUG   Registering shutdown blocker for <unnamed-provider>
1458659378323   addons.manager  DEBUG   Provider finished startup: <unnamed-provider>
1458659378641   DeferredSave.extensions.json    DEBUG   Write succeeded
1458659378642   addons.xpi-utils    DEBUG   XPI Database saved, setting schema version preference to 17
1458659378642   DeferredSave.extensions.json    DEBUG   Starting timer
1458659378667   DeferredSave.extensions.json    DEBUG   Starting write
1458659378677   addons.repository   DEBUG   No addons.json found.
1458659378678   DeferredSave.addons.json    DEBUG   Save changes
1458659378684   DeferredSave.addons.json    DEBUG   Starting timer
1458659378730   addons.manager  DEBUG   Starting provider: PreviousExperimentProvider
1458659378730   addons.manager  DEBUG   Registering shutdown blocker for PreviousExperimentProvider
1458659378731   addons.manager  DEBUG   Provider finished startup: PreviousExperimentProvider
1458659378742   DeferredSave.addons.json    DEBUG   Starting write
1458659378755   DeferredSave.extensions.json    DEBUG   Write succeeded

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message
1458659378851   DeferredSave.addons.json    DEBUG   Write succeeded

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: host: 'selenium', ip: '127.0.0.1', os.name: 'Linux', os.arch: 'amd64', os.version: '3.13.0-59-generic', java.version: '1.8.0_72'
Driver info: driver.version: FirefoxDriver
    at org.openqa.selenium.firefox.internal.NewProfileExtensionConnection.start(NewProfileExtensionConnection.java:124)
    at org.openqa.selenium.firefox.FirefoxDriver.startClient(FirefoxDriver.java:271)
    at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:119)
    at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:218)
    at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:211)
    at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:207)
    at com.smartbear.tests.examples.SimpleWebTest.init(SimpleWebTest.java:158)
    at com.smartbear.tests.examples.SimpleWebTest.<init>(SimpleWebTest.java:130)
    at com.smartbear.tests.examples.SimpleWebTest$1.run(SimpleWebTest.java:82)
    at java.lang.Thread.run(Thread.java:745)
Caused by: org.openqa.selenium.firefox.NotConnectedException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. Firefox console output:
    Updating database with changes to installed add-ons
1458659376845   addons.xpi-utils    DEBUG   Updating add-on states
1458659376846   addons.xpi-utils    DEBUG   Writing add-ons list
1458659376847   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376848   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.0
1458659376848   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376848   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.0
1458659376850   addons.xpi  DEBUG   Registering manifest for /opt/firefox_dev_jmb/browser/features/[email protected]
1458659376850   addons.xpi  DEBUG   Calling bootstrap method startup on [email protected] version 1.1.12
1458659376873   addons.manager  DEBUG   Registering shutdown blocker for XPIProvider
1458659376873   addons.manager  DEBUG   Provider finished startup: XPIProvider
1458659376873   addons.manager  DEBUG   Starting provider: LightweightThemeManager
1458659376873   addons.manager  DEBUG   Registering shutdown blocker for LightweightThemeManager
1458659376874   addons.manager  DEBUG   Provider finished startup: LightweightThemeManager
1458659376874   addons.manager  DEBUG   Starting provider: GMPProvider
1458659376880   addons.manager  DEBUG   Registering shutdown blocker for GMPProvider
1458659376881   addons.manager  DEBUG   Provider finished startup: GMPProvider
1458659376881   addons.manager  DEBUG   Starting provider: PluginProvider
1458659376881   addons.manager  DEBUG   Registering shutdown blocker for PluginProvider
1458659376881   addons.manager  DEBUG   Provider finished startup: PluginProvider
1458659376882   addons.manager  DEBUG   Completed startup sequence

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message
1458659378322   addons.manager  DEBUG   Starting provider: <unnamed-provider>
1458659378322   addons.manager  DEBUG   Registering shutdown blocker for <unnamed-provider>
1458659378323   addons.manager  DEBUG   Provider finished startup: <unnamed-provider>
1458659378641   DeferredSave.extensions.json    DEBUG   Write succeeded
1458659378642   addons.xpi-utils    DEBUG   XPI Database saved, setting schema version preference to 17
1458659378642   DeferredSave.extensions.json    DEBUG   Starting timer
1458659378667   DeferredSave.extensions.json    DEBUG   Starting write
1458659378677   addons.repository   DEBUG   No addons.json found.
1458659378678   DeferredSave.addons.json    DEBUG   Save changes
1458659378684   DeferredSave.addons.json    DEBUG   Starting timer
1458659378730   addons.manager  DEBUG   Starting provider: PreviousExperimentProvider
1458659378730   addons.manager  DEBUG   Registering shutdown blocker for PreviousExperimentProvider
1458659378731   addons.manager  DEBUG   Provider finished startup: PreviousExperimentProvider
1458659378742   DeferredSave.addons.json    DEBUG   Starting write
1458659378755   DeferredSave.extensions.json    DEBUG   Write succeeded

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message
1458659378851   DeferredSave.addons.json    DEBUG   Write succeeded

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

(firefox:29623): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
//bin/dbus-launch terminated abnormally without any error message

    at org.openqa.selenium.firefox.internal.NewProfileExtensionConnection.start(NewProfileExtensionConnection.java:112)
    ... 9 more

javiermorante avatar Mar 22 '16 15:03 javiermorante

We're unlikely to fix this and you should start using Marionete -

https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver

lukeis avatar Mar 22 '16 16:03 lukeis

Thanks lukeis. Sorry, I forgot to add a comment indicating that I have already checked that with Marionette it works fine, so I can use it as a workaround.

So, based on your comment, do you think that FirefoxDriver will be discontinued? Or it is just a non urgent issue as it is just impacting the developer version?

javiermorante avatar Mar 22 '16 17:03 javiermorante

FirefoxDriver will be discontinued. 3.0 will have Marionette as the default running implementation and anyone wanting to run Firefox 45 and below will be able to use the 'old' FirefoxDriver.

lukeis avatar Mar 22 '16 17:03 lukeis

Ok, thanks for the clarification! In that case I proceed to close the issue.

javiermorante avatar Mar 22 '16 17:03 javiermorante

@javiermorante I am trying to run basic selenium webdriver script on FF 47, selenium 2.53.0 jar, My browser is popped up but get "Firefox is stopped working" and I have to close the browser abruptly. Can you please help me with it ? My script is

    DesiredCapabilities capabilities = DesiredCapabilities.firefox();
    capabilities.setCapability("marionette", true);
    WebDriver driver = new FirefoxDriver(capabilities);
     driver.navigate().to("http://google.com");

sandeepjain1987 avatar Jun 18 '16 16:06 sandeepjain1987

@sandeepjain1987 - this is not the correct forum to ask for help. Use Stack Overflow or the Selenium Users Mailing List

That being said, your issue with FF 47 & Selenium 2.53 is explained here: http://www.theautomatedtester.co.uk/blog/2016/selenium-webdriver-and-firefox-47.html

titusfortner avatar Jun 18 '16 17:06 titusfortner

I got it resolved by 2.43.1 standalone server jar files & FF 35.0.1

kyogaraj avatar Jul 18 '16 21:07 kyogaraj