SeleniumHQ / selenium-google-code-issue-archive

Archive, please see main selenium repo
https://github.com/seleniumhq/selenium
346 stars 194 forks source link

Command Line Server for IEDriver Has Stopped Working #8291

Closed lukeis closed 8 years ago

lukeis commented 8 years ago

Originally reported on Google Code with ID 8291

Selenium version: 2.44.0
OS: Windows XP
Browser: Internet Explorer
Browser version: 8

This happens error happens intermittently with the IEDriverServer, typically within
the first ten minutes. Afterwards the node does not open up another session, although
the hub is reporting that one is available and that it is trying to open one. IE doesn't
crash. After I manually close IE and wait a while, the hub/node will try to continue
tests although it seems to hang.

Here is the command line log from just before this happened:

15:10:21.782 INFO - Executing: [find element: By.partialLinkText: Active Referra
ls])
15:10:21.832 INFO - Done: [find element: By.partialLinkText: Active Referrals]
15:10:21.832 INFO - Executing: [click: 10 [[InternetExplorerDriver: internet exp
lorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> partial link text: A
ctive Referrals]])
15:10:21.963 INFO - Done: [click: 10 [[InternetExplorerDriver: internet explorer
 on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> partial link text: Active
 Referrals]]
15:10:21.963 INFO - Executing: [find element: By.xpath: //div[contains(@id, 'das
hboardARDTab')]//tbody[contains(@id, 'Dashboard_data')]/tr[child::td[contains(te
xt(), 'Referrals') and contains(text(), 'Active')] and child::td[contains(text()
, 'CCAC In Home/Community Referral')]]/td[1]])
15:10:42.422 WARN - Exception thrown
org.openqa.selenium.NoSuchElementException: Unable to find element with xpath ==
 //div[contains(@id, 'dashboardARDTab')]//tbody[contains(@id, 'Dashboard_data')]
/tr[child::td[contains(text(), 'Referrals') and contains(text(), 'Active')] and
child::td[contains(text(), 'CCAC In Home/Community Referral')]]/td[1] (WARNING:
The server did not provide any stacktrace information)
Command duration or timeout: 20.14 seconds
For documentation on this error, please visit: http://seleniumhq.org/exceptions/
no_such_element.html
Build info: version: '2.44.0', revision: '76d78cf', time: '2014-10-23 20:02:37'
System info: host: 'purplevm', ip: '192.168.8.140', os.name: 'Windows XP', os.ar
ch: 'x86', os.version: '5.1', java.version: '1.7.0_67'
Session ID: 7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753
Driver info: org.openqa.selenium.ie.InternetExplorerDriver
Capabilities [{platform=WINDOWS, javascriptEnabled=true, elementScrollBehavior=0
, ignoreZoomSetting=false, enablePersistentHover=true, ie.ensureCleanSession=fal
se, browserName=internet explorer, enableElementCacheCleanup=true, unexpectedAle
rtBehaviour=dismiss, version=8, ie.usePerProcessProxy=false, ignoreProtectedMode
Settings=false, cssSelectorsEnabled=true, requireWindowFocus=false, initialBrows
erUrl=http://localhost:63067/, handlesAlerts=true, ie.forceCreateProcessApi=fals
e, nativeEvents=true, browserAttachTimeout=0, ie.browserCommandLineSwitches=, ta
kesScreenshot=true}]
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

        at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)

        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Sou
rce)
        at java.lang.reflect.Constructor.newInstance(Unknown Source)
        at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.
java:204)
        at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHa
ndler.java:156)
        at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.ja
va:599)
        at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDrive
r.java:352)
        at org.openqa.selenium.remote.RemoteWebDriver.findElementByXPath(RemoteW
ebDriver.java:449)
        at org.openqa.selenium.By$ByXPath.findElement(By.java:357)
        at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDrive
r.java:344)
        at sun.reflect.GeneratedMethodAccessor15.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.openqa.selenium.support.events.EventFiringWebDriver$2.invoke(Even
tFiringWebDriver.java:101)
        at com.sun.proxy.$Proxy1.findElement(Unknown Source)
        at org.openqa.selenium.support.events.EventFiringWebDriver.findElement(E
ventFiringWebDriver.java:184)
        at org.openqa.selenium.remote.server.handler.FindElement.call(FindElemen
t.java:47)
        at org.openqa.selenium.remote.server.handler.FindElement.call(FindElemen
t.java:1)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at org.openqa.selenium.remote.server.DefaultSession$1.run(DefaultSession
.java:168)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at java.lang.Thread.run(Unknown Source)
15:10:42.422 WARN - Exception: Unable to find element with xpath == //div[contai
ns(@id, 'dashboardARDTab')]//tbody[contains(@id, 'Dashboard_data')]/tr[child::td
[contains(text(), 'Referrals') and contains(text(), 'Active')] and child::td[con
tains(text(), 'CCAC In Home/Community Referral')]]/td[1] (WARNING: The server di
d not provide any stacktrace information)
Command duration or timeout: 20.14 seconds
For documentation on this error, please visit: http://seleniumhq.org/exceptions/
no_such_element.html
Build info: version: '2.44.0', revision: '76d78cf', time: '2014-10-23 20:02:37'
System info: host: 'purplevm', ip: '192.168.8.140', os.name: 'Windows XP', os.ar
ch: 'x86', os.version: '5.1', java.version: '1.7.0_67'
Session ID: 7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753
Driver info: org.openqa.selenium.ie.InternetExplorerDriver
Capabilities [{platform=WINDOWS, javascriptEnabled=true, elementScrollBehavior=0
, ignoreZoomSetting=false, enablePersistentHover=true, ie.ensureCleanSession=fal
se, browserName=internet explorer, enableElementCacheCleanup=true, unexpectedAle
rtBehaviour=dismiss, version=8, ie.usePerProcessProxy=false, ignoreProtectedMode
Settings=false, cssSelectorsEnabled=true, requireWindowFocus=false, initialBrows
erUrl=http://localhost:63067/, handlesAlerts=true, ie.forceCreateProcessApi=fals
e, nativeEvents=true, browserAttachTimeout=0, ie.browserCommandLineSwitches=, ta
kesScreenshot=true}]
15:10:42.452 INFO - Executing: [implicitly wait: 2000])
15:10:42.462 INFO - Done: [implicitly wait: 2000]
15:10:42.462 INFO - Executing: [find element: By.selector: div[id*='dashboardARD
Tab'] div[id$='Dashboard_paginator_bottom'] > span[class*='ui-paginator-current'
]])
15:10:42.522 INFO - Done: [find element: By.selector: div[id*='dashboardARDTab']
 div[id$='Dashboard_paginator_bottom'] > span[class*='ui-paginator-current']]
15:10:42.522 INFO - Executing: [get text: 11 [[InternetExplorerDriver: internet
explorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector: div
[id*='dashboardARDTab'] div[id$='Dashboard_paginator_bottom'] > span[class*='ui-
paginator-current']]])
15:10:42.582 INFO - Done: [get text: 11 [[InternetExplorerDriver: internet explo
rer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector: div[id*=
'dashboardARDTab'] div[id$='Dashboard_paginator_bottom'] > span[class*='ui-pagin
ator-current']]]
15:10:42.582 INFO - Executing: [find element: By.selector: div[id*='dashboardARD
Tab'] div[id$='Dashboard_paginator_bottom'] span[class*='ui-paginator-next'][cla
ss*='ui-state-default']])
15:10:42.642 INFO - Done: [find element: By.selector: div[id*='dashboardARDTab']
 div[id$='Dashboard_paginator_bottom'] span[class*='ui-paginator-next'][class*='
ui-state-default']]
15:10:42.642 INFO - Executing: [click: 12 [[InternetExplorerDriver: internet exp
lorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector: div[id
*='dashboardARDTab'] div[id$='Dashboard_paginator_bottom'] span[class*='ui-pagin
ator-next'][class*='ui-state-default']]])
15:10:43.223 INFO - Done: [click: 12 [[InternetExplorerDriver: internet explorer
 on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector: div[id*='da
shboardARDTab'] div[id$='Dashboard_paginator_bottom'] span[class*='ui-paginator-
next'][class*='ui-state-default']]]
15:10:43.233 INFO - Executing: [implicitly wait: 5000])
15:10:43.243 INFO - Done: [implicitly wait: 5000]
15:10:43.243 INFO - Executing: [find element: By.selector: div[id$='_start'] img
[src$='throbber.gif']])
15:10:43.313 INFO - Done: [find element: By.selector: div[id$='_start'] img[src$
='throbber.gif']]
15:10:43.313 INFO - Executing: [is displayed: 13 [[InternetExplorerDriver: inter
net explorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector:
 div[id$='_start'] img[src$='throbber.gif']]])
15:10:43.353 INFO - Done: [is displayed: 13 [[InternetExplorerDriver: internet e
xplorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector: div[
id$='_start'] img[src$='throbber.gif']]]
15:10:43.864 INFO - Executing: [find element: By.selector: div[id$='_start'] img
[src$='throbber.gif']])
15:10:43.934 INFO - Done: [find element: By.selector: div[id$='_start'] img[src$
='throbber.gif']]
15:10:43.934 INFO - Executing: [is displayed: 13 [[InternetExplorerDriver: inter
net explorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector:
 div[id$='_start'] img[src$='throbber.gif']]])
15:10:43.984 INFO - Done: [is displayed: 13 [[InternetExplorerDriver: internet e
xplorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector: div[
id$='_start'] img[src$='throbber.gif']]]
15:10:44.485 INFO - Executing: [find element: By.selector: div[id$='_start'] img
[src$='throbber.gif']])
15:10:44.545 INFO - Done: [find element: By.selector: div[id$='_start'] img[src$
='throbber.gif']]
15:10:44.545 INFO - Executing: [is displayed: 13 [[InternetExplorerDriver: inter
net explorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector:
 div[id$='_start'] img[src$='throbber.gif']]])
15:10:44.585 INFO - Done: [is displayed: 13 [[InternetExplorerDriver: internet e
xplorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> css selector: div[
id$='_start'] img[src$='throbber.gif']]]
15:10:44.585 INFO - Executing: [implicitly wait: 20000])
15:10:44.605 INFO - Done: [implicitly wait: 20000]
15:10:44.605 INFO - Executing: [implicitly wait: 20000])
15:10:44.625 INFO - Done: [implicitly wait: 20000]
15:10:44.625 INFO - Executing: [find element: By.xpath: //div[contains(@id, 'das
hboardARDTab')]//tbody[contains(@id, 'Dashboard_data')]/tr[child::td[contains(te
xt(), 'Referrals') and contains(text(), 'Active')] and child::td[contains(text()
, 'CCAC In Home/Community Referral')]]/td[1]])
15:10:44.685 INFO - Done: [find element: By.xpath: //div[contains(@id, 'dashboar
dARDTab')]//tbody[contains(@id, 'Dashboard_data')]/tr[child::td[contains(text(),
 'Referrals') and contains(text(), 'Active')] and child::td[contains(text(), 'CC
AC In Home/Community Referral')]]/td[1]]
15:10:44.685 INFO - Executing: [click: 14 [[InternetExplorerDriver: internet exp
lorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> xpath: //div[contain
s(@id, 'dashboardARDTab')]//tbody[contains(@id, 'Dashboard_data')]/tr[child::td[
contains(text(), 'Referrals') and contains(text(), 'Active')] and child::td[cont
ains(text(), 'CCAC In Home/Community Referral')]]/td[1]]])
15:10:45.036 INFO - Done: [click: 14 [[InternetExplorerDriver: internet explorer
 on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> xpath: //div[contains(@id
, 'dashboardARDTab')]//tbody[contains(@id, 'Dashboard_data')]/tr[child::td[conta
ins(text(), 'Referrals') and contains(text(), 'Active')] and child::td[contains(
text(), 'CCAC In Home/Community Referral')]]/td[1]]]
15:10:45.036 INFO - Executing: [implicitly wait: 5000])
15:10:45.046 INFO - Done: [implicitly wait: 5000]
15:10:45.046 INFO - Executing: [find element: By.xpath: //button[contains(., 'Ma
nage Referrals')]])
15:10:45.086 INFO - Done: [find element: By.xpath: //button[contains(., 'Manage
Referrals')]]
15:10:45.086 INFO - Executing: [is displayed: 15 [[InternetExplorerDriver: inter
net explorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> xpath: //butt
on[contains(., 'Manage Referrals')]]])
15:10:45.126 INFO - Done: [is displayed: 15 [[InternetExplorerDriver: internet e
xplorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> xpath: //button[co
ntains(., 'Manage Referrals')]]]
15:10:45.126 INFO - Executing: [is enabled: 15 [[InternetExplorerDriver: interne
t explorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> xpath: //button
[contains(., 'Manage Referrals')]]])
15:10:45.166 INFO - Done: [is enabled: 15 [[InternetExplorerDriver: internet exp
lorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> xpath: //button[cont
ains(., 'Manage Referrals')]]]
15:10:45.166 INFO - Executing: [implicitly wait: 20000])
15:10:45.166 INFO - Done: [implicitly wait: 20000]
15:10:45.176 INFO - Executing: [find element: By.xpath: //button[contains(., 'Ma
nage Referrals')]])
15:10:45.216 INFO - Done: [find element: By.xpath: //button[contains(., 'Manage
Referrals')]]
15:10:45.216 INFO - Executing: [click: 15 [[InternetExplorerDriver: internet exp
lorer on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> xpath: //button[cont
ains(., 'Manage Referrals')]]])
15:10:45.566 INFO - Done: [click: 15 [[InternetExplorerDriver: internet explorer
 on WINDOWS (7fd7b9d9-e4af-48d3-9c31-3c8e9c0e2753)] -> xpath: //button[contains(
., 'Manage Referrals')]]]
15:10:45.577 INFO - Executing: [implicitly wait: 5000])
15:10:45.617 INFO - Done: [implicitly wait: 5000]
15:10:45.617 INFO - Executing: [find element: By.selector: div[id$='ActiveReferr
als']])
15:11:44.151 ERROR - Unexpected exception during findElement
org.openqa.selenium.remote.UnreachableBrowserException: Error communicating with
 the remote browser. It may have died.
Build info: version: '2.44.0', revision: '76d78cf', time: '2014-10-23 20:02:37'
System info: host: 'purplevm', ip: '192.168.8.140', os.name: 'Windows XP', os.ar
ch: 'x86', os.version: '5.1', java.version: '1.7.0_67'
Driver info: driver.version: EventFiringWebDriver
        at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.ja
va:593)
        at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDrive
r.java:352)
        at org.openqa.selenium.remote.RemoteWebDriver.findElementByCssSelector(R
emoteWebDriver.java:441)
        at org.openqa.selenium.By$ByCssSelector.findElement(By.java:426)
        at org.openqa.selenium.remote.RemoteWebDriver.findElement(RemoteWebDrive
r.java:344)
        at sun.reflect.GeneratedMethodAccessor15.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.openqa.selenium.support.events.EventFiringWebDriver$2.invoke(Even
tFiringWebDriver.java:101)
        at com.sun.proxy.$Proxy1.findElement(Unknown Source)
        at org.openqa.selenium.support.events.EventFiringWebDriver.findElement(E
ventFiringWebDriver.java:184)
        at org.openqa.selenium.remote.server.handler.FindElement.call(FindElemen
t.java:47)
        at org.openqa.selenium.remote.server.handler.FindElement.call(FindElemen
t.java:1)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at org.openqa.selenium.remote.server.DefaultSession$1.run(DefaultSession
.java:168)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at java.lang.Thread.run(Unknown Source)
Caused by: org.openqa.selenium.WebDriverException: org.apache.http.conn.HttpHost
ConnectException: Connect to localhost:63067 [localhost/127.0.0.1] failed: Conne
ction refused: connect
Build info: version: '2.44.0', revision: '76d78cf', time: '2014-10-23 20:02:37'
System info: host: 'purplevm', ip: '192.168.8.140', os.name: 'Windows XP', os.ar
ch: 'x86', os.version: '5.1', java.version: '1.7.0_67'
Driver info: driver.version: EventFiringWebDriver
        at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(Driv
erCommandExecutor.java:75)
        at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.ja
va:572)
        ... 17 more
Caused by: org.apache.http.conn.HttpHostConnectException: Connect to localhost:6
3067 [localhost/127.0.0.1] failed: Connection refused: connect
        at org.apache.http.impl.conn.HttpClientConnectionOperator.connect(HttpCl
ientConnectionOperator.java:140)
        at org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(
PoolingHttpClientConnectionManager.java:318)
        at org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClie
ntExec.java:363)
        at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.
java:219)
        at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java
:195)
        at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:86)
        at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java
:108)
        at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttp
Client.java:184)
        at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttp
Client.java:72)
        at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttp
Client.java:57)
        at org.openqa.selenium.remote.HttpCommandExecutor.fallBackExecute(HttpCo
mmandExecutor.java:233)
        at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExe
cutor.java:184)
        at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(Driv
erCommandExecutor.java:66)
        ... 18 more
Caused by: java.net.ConnectException: Connection refused: connect
        at java.net.TwoStacksPlainSocketImpl.socketConnect(Native Method)
        at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
        at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
        at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
        at java.net.PlainSocketImpl.connect(Unknown Source)
        at java.net.SocksSocketImpl.connect(Unknown Source)
        at java.net.Socket.connect(Unknown Source)
        at org.apache.http.conn.socket.PlainConnectionSocketFactory.connectSocke
t(PlainConnectionSocketFactory.java:72)
        at org.apache.http.impl.conn.HttpClientConnectionOperator.connect(HttpCl
ientConnectionOperator.java:123)
        ... 30 more
15:11:44.291 INFO - Executing: [take screenshot])

Reported by david.b@stratahealth.com on 2014-12-15 22:24:58

lukeis commented 8 years ago
Some additional information:

It doesn't happen consistently on one page; it does seem to happen more often on more
complex pages, however. Upon closing the error (i.e. "Don't send" to Microsoft) the
page fully renders, although the tests will have failed. TestNG shows a stack trace
saying the hub has lost communication to the browser.

I have some screenshots of the error messages but I am unable to attach them to this
thread.. Quota is exceeded.

Reported by david.b@stratahealth.com on 2014-12-15 23:41:42

lukeis commented 8 years ago
Hi I am encountering this issue intermittently too. May we I know what kind of logs
are needed by the development team to help assess what is the issue?

My configuration is as follows.
Windows 7 64Bit
Internet Explorer 11.0.9
C# using .NET 4.0

Reported by ricson.chua on 2015-02-12 07:35:44

lukeis commented 8 years ago
I'm getting this error as well, it happens after some tests 10-30min into them, but
it seems kinda random. I can't see any errors in the iedriver logfile or the output
of the selenium driver.

I can attach the log files, or any other file if needed.

Reported by amund.johnsen on 2015-02-16 15:58:11

lukeis commented 8 years ago
Closing the issue as it does not include exact steps to reproduce it.

Reported by barancev on 2015-03-31 19:35:39

lukeis commented 8 years ago

Reported by luke.semerau on 2015-09-17 18:24:58