cypress: Failure during cypress verify step --smoke-test / throwing at makeError
Current behavior:
We have a few issues floating around about errors during cypress verify that we have not been able to reproduce and have not been fixed as of Cypress v3.3.2.
This issue is the epic issue to track them all in one place. All the other issues have been closed and direct users to comment here.
- https://github.com/cypress-io/cypress/issues/4613
- https://github.com/cypress-io/cypress/issues/4442
- https://github.com/cypress-io/cypress/issues/4258
- https://github.com/cypress-io/cypress/issues/3901
- https://github.com/cypress-io/cypress/issues/3254
- https://github.com/cypress-io/cypress/issues/3176
- https://github.com/cypress-io/cypress/issues/3116
- https://github.com/cypress-io/cypress/issues/3013#issuecomment-450389632
- https://github.com/cypress-io/cypress/issues/2797
- https://github.com/cypress-io/cypress/issues/1866
- https://github.com/cypress-io/cypress/issues/1556#issuecomment-405548988
The error looks something like this:
It looks like this is your first time using Cypress: xxx
✖ Verifying Cypress can run /Users/benjamin/Library/Caches/Cypress/xxx/Cypress.app
→ Cypress Version: xxx
Cypress failed to start.
This is usually caused by a missing library or dependency.
The error below should indicate which dependency is missing.
https://on.cypress.io/required-dependencies
If you are using Docker, we provide containers with all required dependencies installed.
----------
Command failed: /Caches/Cypress/xxx/Cypress.app/Contents/MacOS/Cypress --smoke-test --ping=584
----------
Platform: xxx
Cypress Version: xxx
Some of the output when run in DEBUG:cypress* mode display this stacktrace at makeError
cypress:cli needs XVFB? false +0ms
cypress:cli smoke test command: ../Cypress --smoke-test --ping=310 +0ms
cypress:cli Smoke test failed: {
Error: Command failed: ../Cypress --smoke-test --ping=310
at makeError (../node_modules/execa/index.js:172:9)
at Promise.all.then.arr (../node_modules/execa/index.js:277:16)
at process._tickCallback (internal/process/next_tick.js:68:7)
code: 1,
stdout: '',
stderr: '',
failed: true,
signal: null,
cmd: '../Cypress --smoke-test --ping=310',
timedOut: false,
killed: false
} +43ms
Verifying Cypress can run /home/circleci/.cache/Cypress/3.1.5/Cypress [failed]
Most of the code values in this stack trace are either 1 or null.
- This code was
9and was solved by running undersudo. - This code was
3221225781- SEE THIS ISSUE INSTEAD: https://github.com/cypress-io/cypress/issues/4625
Some people mentioned fixes?
Some people mentioned that restarting their computer fixed it. /shrug
- https://github.com/cypress-io/cypress/issues/4258#issuecomment-498004337
- https://github.com/cypress-io/cypress/issues/3254#issuecomment-459441739
Steps to reproduce: (app code and test code)
Basically any way you can run or open Cypress - people run into this issue
npx cypress opencypress open./node_modules/cypress/bin/cypress openyarn cypress run
Versions
Cypress Versions: 3.0.1 ~ 3.3.1 OS Versions:
- darwin (18.2.0)
- darwin (18.0.0)
- darwin (17.6.0)
- darwin (17.5.0)
- macOS Mojave 10.14.3
- Debian 9.6
- linux (Debian - 9.8)
- linux (Ubuntu Linux - 18.04)
- win32 (6.3.9600)
- win32 (10.0.17134)
Try this before commenting!
- Update to the most recent version of Cypress: https://on.cypress.io/changelog
- Clear your cache by running
cypress cache clear - Try to run
cypress verifyBY ITSELF (notcypress openorcypress run) - Ensure dependencies are installed
sudo apt-get install xvfb libgtk2.0-0 libnotify-dev libgconf-2-4 libnss3 libxss1 libasound2
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 5
- Comments: 24 (6 by maintainers)
What worked for me in 3.4.1 was clearing the cache and re-installing:
Problem still persists in
3.4.1Thank you @msabramo for the detailed log and Dockerfile. I have built your Dockerfile locally and I can recreate the error IF I limit the CPU allocated to the container to a very small number. Here is my command (I commented out
cypress verifycommand from the Docker built)which makes me suspect that in an underpowered container, verification should use a higher time limit. I could pass verification by increasing the timeout in the node_modules/cypress/lib/tasks/verify.js file, so we should probably bump this in our code by default.
We are running Cypress 3.7.0 and we see this problem periodically as well. We run Cypress in Docker containers as part of our CI and sometimes they may be underpowered, as has been noted in this issue. Unfortunately the logs don’t really provide any color here:
It would appear that 30 seconds is sometimes just not enough time. Is there some way we can set this timeout in our Cypress config? Or a way we can disable this test altogether? Either of these would be much more preferable than Cypress failing, which wastes a lot of our time because our tasks have to be restarted.
Released in
3.4.1.Hi together, I had the same issue, but could fix it finally, but this might only apply to the people who in their logs have
Workaround: adjust smoketest timeout per hand in
node_modules\cypress\lib\tasks\verify.jseg.smokeTestTimeout: 1500tosmokeTestTimeout: 100000I guess it might be due to my AntiVirus or Company policy checks, that it takes much longer than the 1.5 seconds.
Feature-Suggestion (does not exist yet): Enabling smokeTestTimeout as an option for
cypress verifylikenpx cypress verify --smokeTestTimeout=100000I hope this can help others.
Platform: win32 (10.0.15063) Cypress Version: 3.3.2
Hi @srideeps In order for us to track down this problem, please try installing Cypress with debug logs enabled and then paste the logs (as a code snippet). You can run Cypress install like this (I would also like to see XVFB records):
or on Windows
Also, in Docker container, could you do the
lddcommand to see if any dependencies are missing? https://docs.cypress.io/guides/guides/debugging.html#Run-the-Cypress-app-by-itself@j-viczian where do you see timing out during
cypress verify? Because we have increased theverifytime out to 10 seconds in https://github.com/cypress-io/cypress/pull/4080Could you paste the debug logs from the timed out verify, please?
Is this option available on mac/linux? Tried both, same error.