Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WaitTimeoutError during test #537

Open
ryuran opened this issue Sep 2, 2017 · 21 comments
Open

WaitTimeoutError during test #537

ryuran opened this issue Sep 2, 2017 · 21 comments

Comments

@ryuran
Copy link

ryuran commented Sep 2, 2017

Helo!

After an error on Travis (OnetapInc/chromy#62), I try to reduce async limit to pass test.

asyncCaptureLimit: 5,
asyncCompareLimit: 50

But nothing change 😢 : https://travis-ci.org/20minutes/colette/builds/271137302

Then I try with

asyncCaptureLimit: 1,
asyncCompareLimit: 1

https://travis-ci.org/20minutes/colette/builds/271199288
I don’t know why it’s green even if i have no result of the test…

@garris
Copy link
Owner

garris commented Sep 2, 2017

Did you try to reduce to 1?

@ryuran
Copy link
Author

ryuran commented Sep 2, 2017

@garris yes, my second try is at 1:1
It’s better but travis return positive whereas backstop was not able to finish test and I have some errors in logs.

ChromyJS returned an unexpected error while attempting to capture a selector. { WaitTimeoutError: evaluate() timeout
    at EvaluateTimeoutError.ExtendableBuiltin (/home/travis/build/20minutes/colette/node_modules/chromy/dist/error.js:44:28)
    at EvaluateTimeoutError.TimeoutError (/home/travis/build/20minutes/colette/node_modules/chromy/dist/error.js:73:128)
    at new EvaluateTimeoutError (/home/travis/build/20minutes/colette/node_modules/chromy/dist/error.js:118:145)
    at Chromy._evaluateWithReplaces$ (/home/travis/build/20minutes/colette/node_modules/chromy/dist/document.js:484:21)
    at tryCatch (/home/travis/build/20minutes/colette/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:65:40)
    at Generator.invoke [as _invoke] (/home/travis/build/20minutes/colette/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:299:22)
    at Generator.prototype.(anonymous function) [as throw] (/home/travis/build/20minutes/colette/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:117:21)
    at tryCatch (/home/travis/build/20minutes/colette/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:65:40)
    at invoke (/home/travis/build/20minutes/colette/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:155:20)
    at /home/travis/build/20minutes/colette/node_modules/babel-runtime/node_modules/regenerator-runtime/runtime.js:167:13
    at <anonymous> name: 'WaitTimeoutError' }

@garris
Copy link
Owner

garris commented Sep 5, 2017

I have just verified that asyncCaptureLimit and asyncCompareLimit are working as designed. At this point I think you need to look at why your particular test is failing.

@garris garris changed the title asyncCaptureLimit and asyncCompareLimit seems not working WaitTimeoutError during test Sep 5, 2017
@ryuran
Copy link
Author

ryuran commented Sep 5, 2017

I add log for test scenario label.
It seems fail on ./docs/item-theme-skins.html or the next one ./docs/item-theme-styles.html.
I check this files with html validator, they are valid.
So I’m blocked. All is fine in local environment.

@kiran-redhat
Copy link
Contributor

@ryuran 1. are you about to find that in chrome console ?

  1. Do you see sale error with asyncCaptureLimit: 1,?

If 1 &2 are yes, clone latest master and test. asyncCaptureLimit and asyncCompareLimit we're working fine for me

@ryuran
Copy link
Author

ryuran commented Sep 5, 2017

@kiran-redhat

  1. I don’t know how to return more info from browser in travis-CI logs
  2. This travis build is running with asyncCaptureLimit: 1 https://travis-ci.org/20minutes/colette/builds/271948792 I have the error

@kiran-redhat
Copy link
Contributor

kiran-redhat commented Sep 5, 2017 via email

@ryuran
Copy link
Author

ryuran commented Sep 5, 2017

No error in my local chrome.
Backstop.js run fine in local environment with all test to green.

I update backstopjs:

└─┬ backstopjs@3.0.24
  └── chromy@0.5.2

And I try to change delay to 200 (it was 100), but it stops always on the same test.
Without error this time but with travis timeout:
https://travis-ci.org/20minutes/colette/builds/271982035

@ryuran
Copy link
Author

ryuran commented Sep 5, 2017

It seems fail most often on test with <img>

@reynaldoapb
Copy link

Try to kill chrome with shell command taskkill /F /IM chrome.exe and run everything again.

@axe312ger
Copy link

Turning it down to

asyncCaptureLimit: 1,
asyncCompareLimit: 1

worked for me on travis :)

@mhavelant
Copy link

mhavelant commented Oct 17, 2017

Hi!

I got the same error. The async limits at 1 did not help, however setting "selectors" to "viewport" from "document" did. So it might be something with chromy with 'document' as the selector.

Edit: Setting asyncCaptureLimit to 1 AND not using "document" together worked. Setting the capture limit to something higher broke it.

@garris
Copy link
Owner

garris commented Oct 17, 2017

What version of chrome and backstop are you using?

@mhavelant
Copy link

The newest ones:

  • Google Chrome 62.0.3202.52 beta
  • BackstopJS v3.0.29

Note: I'm running under a dockerized Ubuntu 16.04

@tfrijsewijk
Copy link

I'm experiencing the same issue, with the same versions as mhavelent

@garris
Copy link
Owner

garris commented Oct 19, 2017

Hello all. Thank you very much for posting.

It may be possible that #561 (running out of memory) is related to this issue — which only seems to happen on Linux.

@vdekov posted a fix for #561 here... #571

Would it be possible for someone to pull this PR and see if the problem resolves?

@mhavelant
Copy link

For me, the error

ChromyJS returned an unexpected error while attempting to capture a selector. { WaitTimeoutError: evaluate() timeout...

is thrown before the 'BackstopTools have been installed.' step in chromy. So long before comparisons are even considered, in the reference command.

So the PR, although sounding insanely good overall, I don't think will help here.

At least for me, it seems that the 'document' selector is not working with Chromy.

@garris
Copy link
Owner

garris commented Oct 19, 2017

Oh. Crap. You’re right. Ok — scratch that. 😕

@kevineye
Copy link

I was getting this WaitTimeoutError, too, not running natively, but when switching to run in docker. Happened more often with higher asyncCaptureLimit and more complex pages, but even sometimes with asyncCaptureLimit: 1.

Eventually tracked the problem down to chrome dying with a bus error, and finally tracked this down to running out of space in /dev/shm. Docker allocates 64MB to /dev/shm by default.

Running docker with --shm-size 512m fixed the issue for me. Lets me run with default asyncCaptureLimit: 10.

@garris
Copy link
Owner

garris commented Oct 26, 2017

@kevineye Nice debugging — thanks for posting!

@garris
Copy link
Owner

garris commented Nov 22, 2017

cross referencing this issue... #603 (comment)

iain17 added a commit to iain17/BackstopJS that referenced this issue Feb 13, 2018
- Changed base image to none alpine. Allowing new chrome version.
- Updated Chrome to the latest (64). Potentially fixing issues garris#603 garris#537
garris pushed a commit that referenced this issue Feb 13, 2018
- Changed base image to none alpine. Allowing new chrome version.
- Updated Chrome to the latest (64). Potentially fixing issues #603 #537
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants