keystone-nightwatch-e2e icon indicating copy to clipboard operation
keystone-nightwatch-e2e copied to clipboard

SauceLabs error: The test with session id null has already finished, and can't receive further commands.

Open webteckie opened this issue 8 years ago • 11 comments

The keystone e2e tests sometimes failed with the following error. Need to figure out why NightwatchJS is not getting notified and/or it is not notifying KNE of any errors.

Running:  Date field should show correctly in the edit form
 ✔ Expected element <.EditForm-container .field-type-text[for="name"] input[name="name"]> to be visible - condition was met in 305ms
 ✔ Expected element <.EditForm-container .field-type-date[for="fieldA"] label[for="fieldA"]> to be visible - condition was met in 299ms
 ✔ Expected element <.EditForm-container .field-type-date[for="fieldA"] label[for="fieldA"]> text to equal: "Field A" - condition was met in 292ms
 ✔ Expected element <.EditForm-container .field-type-date[for="fieldA"] input[name="fieldA"]> to be visible - condition was met in 297ms
13:49:21:641 Sauce Connect: Closing Sauce Connect Tunnel
 ✔ Expected element <.EditForm-container .field-type-date[for="fieldA"] button> to be visible - condition was met in 296ms
 ✔ Expected element <.EditForm-container .field-type-date[for="fieldB"] label[for="fieldB"]> to be visible - condition was met in 295ms
 ✔ Expected element <.EditForm-container .field-type-date[for="fieldB"] label[for="fieldB"]> text to equal: "Field B" - condition was met in 295ms
 ✔ Expected element <.EditForm-container .field-type-date[for="fieldB"] input[name="fieldB"]> to be visible - condition was met in 317ms
 ✔ Expected element <.EditForm-container .field-type-date[for="fieldB"] button> to be visible - condition was met in 309ms
OK. 9 assertions passed. (2.714s)
Running:  Date field can be filled via the edit form
 ✔ Element <div[data-screen-id="item"]> was visible after 287 milliseconds.
 ✖ Expected element <div[data-alert-type="success"]> text to equal: "Your changes have been saved successfully" - element was not found  - expected "present" but got: "not present"
    at Object.Date field can be filled via the edit form (/home/travis/build/keystonejs/keystone/test/e2e/adminUI/tests/group006Fields/testDateField.js:84:29)
    at _combinedTickCallback (internal/process/next_tick.js:67:7)
    at process._tickCallback (internal/process/next_tick.js:98:9)
FAILED:  1 assertions failed and 1 passed (1m 4s / 64966ms)
Error processing the server response: 
 ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages
Error processing the server response: 
 ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages
Error processing the server response: 
 ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages
Error processing the server response: 
 ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages
Error processing the server response: 
 ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages
Error processing the server response: 
 ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages
Error processing the server response: 
 ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages
Error processing the server response: 
 ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages
Error processing the server response: 

webteckie avatar Jan 25 '17 23:01 webteckie

Did you get any resolution to this. We are experiencing a similar issue across chrome and firefox

DomSkech avatar Mar 13 '17 13:03 DomSkech

Hi @DomSkech no, we haven't look into it, yet.

Curious, are you experiencing this with a keystone-nightwatch-e2e setup or your own nightwatch setup?

webteckie avatar Mar 13 '17 13:03 webteckie

Our own nightwatch setup. The same suite run perfectly well running locally against the remote test servers. Its only in saucelabs that this issue manifests itself.

Interestingly all my tests still appear to 'pass'. Although the logs show the same as you see.

If you can eliminate keystone then perhaps we should escalate this to SauceLabs?

DomSkech avatar Mar 13 '17 13:03 DomSkech

Cool...if you find anything enlightening please share...we'll do the same!

webteckie avatar Mar 13 '17 14:03 webteckie

I'm seeing the same error when running our nightwatch test suite as well. For us is happening when we run the tests in parallel across a number of different browsers.

Would be nice if we could get some guidance from SauceLabs on how to further investigate the root cause for this issue.

gabid-asos avatar Mar 14 '17 18:03 gabid-asos

Yes we having issues here too :(

ERROR The test with session id null has already finished, and can't receive further commands.
You can learn more at https://saucelabs.com/jobs/null
For help, please check https://wiki.saucelabs.com/display/DOCS/Common+Error+Messages

gilmillasseau avatar Mar 15 '17 17:03 gilmillasseau

I am also getting the similar error. But my case it's not parallel execution but sequential only. Anyone figured out any workarounds for this problem?? your quick help is much appreciated!!!

Prasannajnaeyulu avatar Mar 25 '17 07:03 Prasannajnaeyulu

Same error here but mine includes a process id:

Failed: The test with session id 0f2b41dc0cd3415c8e84013532f3e464 has already finished, and can't receive further commands.

usumoio avatar Mar 29 '17 21:03 usumoio

It is probably worth logging these errors either with TravisCI or with SauceLabs. It's clear from the amount of people having this problem that it's not really anything to do with Keystone-nightwatch-e2e, and as such nothing is going to be fixed because of this issue...

jstockwin avatar May 03 '17 18:05 jstockwin

For posterity...

Similar error, but we get a session id. Occurs on SauceLabs only and does not occur locally. Using protractor and chrome.

ldeavila avatar Sep 08 '17 17:09 ldeavila

A bit more for posterity...

Solved the issue with a combo of sauce config changes:

{ maxInstances: 100, seleniumVersion: "3.5.3", chromedriverVersion: "2.32", commandTimeout: 600, maxDuration: 1200 }

ldeavila avatar Sep 11 '17 02:09 ldeavila