zb226
zb226

Reputation: 10500

Selenium RC: "waiting for window 'null' local frame 'null'"

I am totally at a loss here, trying to run a minimal Selenium RC style test. The issue I'm experiencing has been described by a lot of users on the web but none of the widely varying solutions solved the problem in my case. What happens is that Firefox will open, but with what looks like an empty profile to me, because it opens the "Welcome to Firefox!" page. Apart from that, nothing happens in the browser and in the Selenium server log I find this:

DEBUG [12] org.openqa.selenium.server.browserlaunchers.BrowserLauncherFactory - Requested browser string '*firefox c:\progra~2\mozill~1\firefox.exe' matches *firefox
DEBUG [12] org.openqa.selenium.browserlaunchers.locators.BrowserLocator - Checking whether Firefox 3 launcher at :'c:\progra~2\mozill~1\firefox.exe' is valid...
DEBUG [12] org.openqa.selenium.browserlaunchers.locators.BrowserLocator - Discovered valid Firefox 3 launcher  : 'c:\progra~2\mozill~1\firefox.exe'
INFO [12] org.openqa.selenium.server.BrowserSessionFactory - Allocated session 962d2221ccb4459b9adbad1b8734850c for http://www.google.com, launching...
DEBUG [12] org.openqa.selenium.server.browserlaunchers.ResourceExtractor - Extracting /customProfileDirCUSTFFCHROME to C:\Users\zb\AppData\Local\Temp\customProfileDir962d2221ccb4459b9adbad1b8734850c
INFO [12] org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher - Preparing Firefox profile...
INFO [12] org.openqa.selenium.server.browserlaunchers.FirefoxChromeLauncher - Launching Firefox...
DEBUG [12] org.openqa.selenium.server.FrameGroupCommandQueueSet - waiting for window 'null' local frame 'null' for 1800 more secs
DEBUG [12] org.openqa.selenium.server.FrameGroupCommandQueueSet - waiting for condition for 1000 more ms
DEBUG [12] org.openqa.selenium.server.FrameGroupCommandQueueSet - got condition? : false

The last three lines are then repeated every second until I stop the Selenium server again.

This is my test code:

import com.thoughtworks.selenium.DefaultSelenium;
public class Runner {
    public static void main(String[] args) {
        DefaultSelenium selenium = new DefaultSelenium("localhost", 4444,
            "*firefox c:\\progra~2\\mozill~1\\firefox.exe", 
            "http://www.google.com");
        selenium.start();
        selenium.open("/");
        selenium.type("q", "test");
        selenium.click("btnK");    
        selenium.stop();
    }
}

I tried:

It all doesn't help and ends up like I described above. I'm on a Windows 7 machine (64bit). By the way, a small WebDriver test I tried works as expected.

Edit: Renamed question, because the server doesn't actually "hang", it just doesn't work as expected.

Upvotes: 2

Views: 781

Answers (2)

akarollil
akarollil

Reputation: 509

I hit the same problem, but I could get around it by updating to selenium-server-standalone-2.35.0.jar from https://code.google.com/p/selenium/downloads/list, with Firefox version 24 installed on Ubuntu 12.04 using apt-get (version is 24.0+build1-0ubuntu0.12.04.1).

Upvotes: 1

zb226
zb226

Reputation: 10500

I went back to Firefox 17 ESR (Extended Support Release) and suddenly the tests came back to life (using Selenium server 2.33.0).

This problem seems to be an indicator for version incompatibilites between Selenium server and Firefox. Unfortunately, there's not much, or anything, to be found in the documentation on this matter - but then again, as @Pavel Janicek mentioned, Selenium RC is deprecated. What I've been able to grasp from the CHANGELOG is that Selenium server 2.32.0 explicitly supports Firefox 10 ESR, 17 ESR, 19 and 20. For 2.33.0, no additional browser versions are mentioned, leaving Firefox 21+ officially unsupported, although not everyone agrees.

To wrap it up: If you see this error, the only solution may be to step down the list of supported browsers in the current CHANGELOG until your tests run again.

Upvotes: 1

Related Questions