Open wagnerpereira opened 2 years ago
The problem seems not to be related exclusively with github actions, it's related with running cypress thought the cypress:run task on linux.
Mac OS has the "tail -r" option, linux don't: Mac OS Monterey:
➜ tia git:(issue-110) cat .tool-versions
ruby 2.7.5
nodejs 12.18.2
redis 6.0.9
➜ tia git:(issue-110) cat .tool-versions | tail -r
redis 6.0.9
nodejs 12.18.2
ruby 2.7.5
Linux Debian / Ubuntu 20.04:
root@1daa76a417c2:/app# cat .tool-versions
ruby 2.7.5
nodejs 12.18.2
redis 6.0.9
root@1daa76a417c2:/app# cat .tool-versions |tail -r
tail: invalid option -- 'r'
Try 'tail --help' for more information.
root@1daa76a417c2:/app#
Nothing's jumping out at me as an apparent cause, at least as it pertains to this gem itself. tail
isn't referenced anywhere in the gem and I'm unsure what in the combined dependency tree might be trying to invoke it with an invalid (in Linux) flag.
Thank you @searls, I will continue to debug this.
Yesterday I discovered that if I run the cypress/github-actions before the rake cypress:run, it's works! So I guess that the cypress action knows how to set some aspect of the environment that is lacking when I'm running cypress:run in github action virtual environment.
I'm trying to find what the problem is.
@searls Trying to read the gem code and check if there is a wait-on method to avoid cypress run start when Rails server is not ready for requests yet ( didn't finish the boot process ). Is there anything like this?
Hmm, I don't think so. Seems feasible as an issue, because every Rails app I test with this gem boots much much faster than Cypress itself does
@searls In fact I have found many issues on cypress github repository with the same > Error: ESOCKETTIMEDOUT on many CI/CD solutions. codebuild, circle CI and github actions.
https://github.com/cypress-io/cypress/issues/7062
I'm still searching to find why this is happening.
Thank you all for all the work made on this gem. It was time saving coming from Rspec/Capybara.
Do you have any idea why I'm getting this "tail -r" error when running in github actions pipeline?
I didn't get this error when using github.com/cypress-io official github action. But I trying away to generate simplecov coverage report and it didn't works using the cypress github action. I guess it is because it is not terminating the rails server process in the end of the tests.
Github actions running results:
Github actions Cypress:
Running on ubuntu:20.04