Issue Details (XML | Word | Printable)

Key: SRC-816
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Patrick Lightbody
Reporter: Andy Belsky
Votes: 1
Watchers: 3
Operations

If you were logged in you would be able to see more operations.
Selenium Remote Control

Browser session fails to start on Firefox 3.6

Created: 05/Feb/10 03:39 AM   Updated: 23/Feb/10 12:24 PM   Resolved: 23/Feb/10 12:23 PM
Component/s: Launcher - Firefox, Server
Affects Version/s: 1.0.1
Fix Version/s: 1.0.3

Environment:
Windows XP SP3; Windows Vista
Firefox 3.6


 Description  « Hide

Selenium server starts OK, but when trying to execute some tests the following error occures:

-------------------------------------------------------
20:21:28.334 INFO - Checking Resource aliases
20:21:28.349 INFO - Command request: getNewBrowserSession[*chrome, http://localhost:8080/konakart/, ] on session null
20:21:28.365 INFO - creating new remote session
20:21:29.802 INFO - Allocated session 0f8f5a8b5e9f4959a73efca935ea3dcf for http://localhost:8080/konakart/, launching...
20:21:30.162 INFO - Preparing Firefox profile...
20:22:05.397 ERROR - Failed to start new browser session, shutdown browser and clear all session data
java.lang.RuntimeException: Firefox refused shutdown while preparing a profile
at org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.waitForFullProfileToBeCreated(FirefoxChromeLauncher.java:311)
at org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.populateCustomProfileDirectory(FirefoxChromeLauncher.java:106)
at org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.launch(FirefoxChromeLauncher.java:83)
at org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.launchRemoteSession(FirefoxChromeLauncher.java:350)
at org.openqa.selenium.server.BrowserSessionFactory.createNewRemoteSession(BrowserSessionFactory.java:357)
at org.openqa.selenium.server.BrowserSessionFactory.getNewBrowserSession(BrowserSessionFactory.java:122)
at org.openqa.selenium.server.BrowserSessionFactory.getNewBrowserSession(BrowserSessionFactory.java:84)
at org.openqa.selenium.server.SeleniumDriverResourceHandler.getNewBrowserSession(SeleniumDriverResourceHandler.java:699)
at org.openqa.selenium.server.SeleniumDriverResourceHandler.doCommand(SeleniumDriverResourceHandler.java:393)
at org.openqa.selenium.server.SeleniumDriverResourceHandler.handleCommandRequest(SeleniumDriverResourceHandler.java:364)
at org.openqa.selenium.server.SeleniumDriverResourceHandler.handle(SeleniumDriverResourceHandler.java:125)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1530)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1482)
at org.mortbay.http.HttpServer.service(HttpServer.java:909)
at org.mortbay.http.HttpConnection.service(HttpConnection.java:820)
at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:986)
at org.mortbay.http.HttpConnection.handle(HttpConnection.java:837)
at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:245)
at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:357)
at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:534)
Caused by: org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher$FileLockRemainedException: Lock file still present! C:\WINDOWS\customProfileDir0f8f5a8b5e9f4959a73efca935ea3dcf\parent.lock
at org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.waitForFileLockToGoAway(FirefoxChromeLauncher.java:269)
at org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.waitForFullProfileToBeCreated(FirefoxChromeLauncher.java:309)
... 19 more
20:22:19.522 INFO - Got result: Failed to start new browser session: Unable to delete file C:\WINDOWS\customProfileDir0f8f5a8b5e9f4959a73efca935ea3dcf\parent.lock on session null
java.lang.RuntimeException: Could not start Selenium session: Failed to start new browser session: Unable to delete file C:\WINDOWS\customProfileDir0f8f5a8b5e9f4959a73efca935ea3dcf\parent.lock
at com.thoughtworks.selenium.DefaultSelenium.start(DefaultSelenium.java:89)
at launcher.TestRunner.startSelenium(TestRunner.java:155)
at launcher.TestRunner.run(TestRunner.java:128)
at launcher.TestRunner.run(TestRunner.java:101)
at launcher.TestRunner.main(TestRunner.java:249)
Caused by: com.thoughtworks.selenium.SeleniumException: Failed to start new browser session: Unable to delete file C:\WINDOWS\customProfileDir0f8f5a8b5e9f4959a73efca935ea3dcf\parent.lock
at com.thoughtworks.selenium.HttpCommandProcessor.throwAssertionFailureExceptionOrError(HttpCommandProcessor.java:97)
at com.thoughtworks.selenium.HttpCommandProcessor.doCommand(HttpCommandProcessor.java:91)
at com.thoughtworks.selenium.HttpCommandProcessor.getString(HttpCommandProcessor.java:262)
at com.thoughtworks.selenium.HttpCommandProcessor.start(HttpCommandProcessor.java:223)
at com.unitedinternet.portal.selenium.utils.logging.LoggingCommandProcessor.start(LoggingCommandProcessor.java:269)
at com.thoughtworks.selenium.DefaultSelenium.start(DefaultSelenium.java:81)
... 4 more

-------------------------------------------------------

Works fine on Firefox 3.5.3



Sort Order: Ascending order - Click to sort in descending order
Andy Belsky added a comment - 05/Feb/10 03:57 AM

And the same error occures with FF 3.6 on XP SP2.


Alain Camus added a comment - 10/Feb/10 06:39 AM

I get this error with Selenium Grid, when trying to do the demo like in http://selenium-grid.seleniumhq.org/run_the_demo.html

The solution mentionned on http://selenium-grid.seleniumhq.org/faq.html doesn't help. Even after killing all firefox, deleting all customProfileDir's folders and rebooting, the demo gives four times the same error (each session blocking itself).

Selenium Grid 1.0.4, Windows XP SP2, Firefox 3.6


Alain Camus added a comment - 10/Feb/10 07:25 AM

Tried RC (1.0.1) again, and got the same error on a test that worked yesterday. The only changes I see is that I tried Selenium Grid and messed with the customProfileDir's folders.

14:16:18.736 INFO - Command request: getNewBrowserSession[*firefox, http://vm-wwwdevel/, ] on session null
14:16:18.736 INFO - creating new remote session
14:16:18.736 INFO - Allocated session 3db6c79ba88e47b0b63d75690426164a for http://vm-wwwdevel/, launching...
14:16:18.861 INFO - Preparing Firefox profile...
14:16:40.427 ERROR - Failed to start new browser session, shutdown browser and clear all session data
java.lang.RuntimeException: Firefox refused shutdown while preparing a profile
        at [...]
Caused by: org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher$FileLockRemainedException: Lock file still present! C:\DOCUME~1\aca\LOCAL
S~1\Temp\customProfileDir3db6c79ba88e47b0b63d75690426164a\parent.lock
        at org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.waitForFileLockToGoAway(FirefoxChromeLauncher.java:269)
        at org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher.waitForFullProfileToBeCreated(FirefoxChromeLauncher.java:309)
        ... 20 more
14:16:52.700 INFO - Got result: Failed to start new browser session: Unable to delete file C:\DOCUME~1\aca\LOCALS~1\Temp\customProfileDir3db6c79ba88e4
7b0b63d75690426164a\parent.lock on session null

Alain Camus added a comment - 10/Feb/10 07:57 AM

I finally remembered I already solved this yesterday for Selenium RC by applying http://www.qaautomation.net/?p=15
I also applied it on selenium-grid-1.0.4\vendor\selenium-server-1.0.1.jar, and Selenium Grid demo works smoothly.


Patrick Lightbody added a comment - 23/Feb/10 12:24 PM