I'm seeing this also.
Mostly while chromedriver is used (it happenes 1-2% in the tests
randomly). I experienced this on both XP and Win7.
If I used chrome driver with FF driver the same time on the same VM it
happened more frequently.
It is totally random when I get this error. I've seen this error while
findElements, click, executescript.... were used. This makes our
chrome tests unstable.
I exclude the local network problems because in that case this should
happen also when Firefox tests run.
Grid is running on a MacMini with Lion. I use json config files for
both grid and node setup, but nothing special in it, copies of the
ones found in the server-standalone jar file with port number, ip
address and actual capabilities modifications.
Here is the last stack trace I got:
org.openqa.selenium.WebDriverException: The target server failed to
respond; duration or timeout: 3.28 seconds
Build info: version: '2.6.0', revision: '13840', time: '2011-09-13
14:55:30'
System info:
os.name: 'Windows 7', os.arch: 'x86', os.version: '6.1',
java.version: '1.7.0'
Driver info: driver.version: RemoteWebDriver
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:
57)
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:
45)
java.lang.reflect.Constructor.newInstance(Constructor.java:525)
org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:
147)
org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:
113)
org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:
397)
org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:
182)
org.openqa.selenium.remote.RemoteWebDriver.findElementByCssSelector(RemoteWebDriver.java:
247)
org.openqa.selenium.By$ByCssSelector.findElement(By.java:401)
org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:
174)
com.Selena.utilities.Utilities.isVisible(Utilities.java:252)
com.Selena.utilities.Utilities$5.apply(Utilities.java:458)
com.Selena.utilities.Utilities$5.apply(Utilities.java:455)
org.openqa.selenium.support.ui.FluentWait.until(FluentWait.java:173)
com.Selena.utilities.Utilities.waitForVisible(Utilities.java:453)
com.Selena.utilities.Utilities.waitForVisible(Utilities.java:423)
com.Selena.BasePage.waitForVisible(BasePage.java:426)
com.Selena.BasePage.waitForVisible(BasePage.java:446)
com.Selena.BasePage.preClickEvents(BasePage.java:602)
com.Selena.BasePage.click(BasePage.java:655)
com.Selena.BasePage.click(BasePage.java:626)
com.Selena.BasePage.click(BasePage.java:613)
com.*********v3.tests.basetest.*********V3BaseTest.startSelenium(*********V3BaseTest.java:
159)
com.Selena.BaseFunctionality.setUp(BaseFunctionality.java:292)
com.*********v3.tests.basetest.*********V3BaseTest.setUp(*********V3BaseTest.java:
143)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
57)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:
43)
java.lang.reflect.Method.invoke(Method.java:601)
org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:
76)
org.testng.internal.Invoker.invokeConfigurationMethod(Invoker.java:
525)
org.testng.internal.Invoker.invokeConfigurations(Invoker.java:202)
org.testng.internal.Invoker.invokeMethod(Invoker.java:613)
org.testng.internal.Invoker.invokeTestMethod(Invoker.java:846)
org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1170)
org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:
125)
org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:109)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
1110)
java.util.concurrent.ThreadPoolExecutor
$Worker.run(ThreadPoolExecutor.java:603)
java.lang.Thread.run(Thread.java:722)
Caused by: org.openqa.selenium.remote.ScreenshotException: Screen shot
has been taken
Build info: version: '2.6.0', revision: '13840', time: '2011-09-13
14:55:30'
System info:
os.name: 'Windows 7', os.arch: 'x86', os.version: '6.1',
java.version: '1.7.0'
Driver info: driver.version: RemoteWebDriver
org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:
101)
org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:
397)
org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:
182)
org.openqa.selenium.remote.RemoteWebDriver.findElementByCssSelector(RemoteWebDriver.java:
247)
org.openqa.selenium.By$ByCssSelector.findElement(By.java:401)
org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:
174)
com.Selena.utilities.Utilities.isVisible(Utilities.java:252)
com.Selena.utilities.Utilities$5.apply(Utilities.java:458)
com.Selena.utilities.Utilities$5.apply(Utilities.java:455)
org.openqa.selenium.support.ui.FluentWait.until(FluentWait.java:173)
com.Selena.utilities.Utilities.waitForVisible(Utilities.java:453)
com.Selena.utilities.Utilities.waitForVisible(Utilities.java:423)
com.Selena.BasePage.waitForVisible(BasePage.java:426)
com.Selena.BasePage.waitForVisible(BasePage.java:446)
com.Selena.BasePage.preClickEvents(BasePage.java:602)
com.Selena.BasePage.click(BasePage.java:655)
com.Selena.BasePage.click(BasePage.java:626)
com.Selena.BasePage.click(BasePage.java:613)
com.*********v3.tests.basetest.*********V3BaseTest.startSelenium(*********V3BaseTest.java:
159)
com.Selena.BaseFunctionality.setUp(BaseFunctionality.java:292)
com.*********v3.tests.basetest.*********V3BaseTest.setUp(*********V3BaseTest.java:
143)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
57)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:
43)
java.lang.reflect.Method.invoke(Method.java:601)
org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:
76)
org.testng.internal.Invoker.invokeConfigurationMethod(Invoker.java:
525)
org.testng.internal.Invoker.invokeConfigurations(Invoker.java:202)
org.testng.internal.Invoker.invokeMethod(Invoker.java:613)
org.testng.internal.Invoker.invokeTestMethod(Invoker.java:846)
org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1170)
org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:
125)
org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:109)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
1110)
java.util.concurrent.ThreadPoolExecutor
$Worker.run(ThreadPoolExecutor.java:603)
java.lang.Thread.run(Thread.java:722)
Caused by: org.apache.http.NoHttpResponseException: The target server
failed to respond
org.apache.http.impl.conn.DefaultResponseParser.parseHead(DefaultResponseParser.java:
101)
org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:
252)
org.apache.http.impl.AbstractHttpClientConnection.receiveResponseHeader(AbstractHttpClientConnection.java:
281)
org.apache.http.impl.conn.DefaultClientConnection.receiveResponseHeader(DefaultClientConnection.java:
247)
org.apache.http.impl.conn.AbstractClientConnAdapter.receiveResponseHeader(AbstractClientConnAdapter.java:
219)
org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:
298)
org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:
125)
org.apache.http.impl.client.DefaultRequestDirector.tryExecute(DefaultRequestDirector.java:
645)
org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:
464)
org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:
820)
org.openqa.selenium.remote.HttpCommandExecutor.fallBackExecute(HttpCommandExecutor.java:
390)
org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:
369)
org.openqa.selenium.chrome.ChromeCommandExecutor.execute(ChromeCommandExecutor.java:
50)
org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:
377)
org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:
182)
org.openqa.selenium.remote.RemoteWebDriver.findElementByCssSelector(RemoteWebDriver.java:
247)
org.openqa.selenium.By$ByCssSelector.findElement(By.java:401)
org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDriver.java:
174)
sun.reflect.GeneratedMethodAccessor16.invoke(Unknown Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
java.lang.reflect.Method.invoke(Unknown Source)
org.openqa.selenium.support.events.EventFiringWebDriver
$2.invoke(EventFiringWebDriver.java:98)
$Proxy1.findElement(Unknown Source)
org.openqa.selenium.support.events.EventFiringWebDriver.findElement(EventFiringWebDriver.java:
177)
org.openqa.selenium.remote.server.handler.FindElement.call(FindElement.java:
48)
org.openqa.selenium.remote.server.handler.FindElement.call(FindElement.java:
1)
java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
java.util.concurrent.FutureTask.run(Unknown Source)
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
java.lang.Thread.run(Unknown Source)
I use RemoteWebDriver because of the grid2 setup. But could not run a
lot IE tests because a java runtime error used to kill the node about
the same frequent as this exception happens in chrome.
But that's should be an other issue but I could not find any solution
for that neither.