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

cypress:run failing on github actions pipeline #113

Open
wagnerpereira opened this issue Feb 21, 2022 · 6 comments
Open

cypress:run failing on github actions pipeline #113

wagnerpereira opened this issue Feb 21, 2022 · 6 comments

Comments

@wagnerpereira
Copy link

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:
Screen Shot 2022-02-21 at 17 57 36

Github actions Cypress:
Screen Shot 2022-02-21 at 18 02 54

Running on ubuntu:20.04

@wagnerpereira
Copy link
Author

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#

@searls
Copy link
Member

searls commented Feb 24, 2022

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.

@wagnerpereira
Copy link
Author

wagnerpereira commented Feb 24, 2022

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.

@wagnerpereira
Copy link
Author

@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?

@searls
Copy link
Member

searls commented Mar 4, 2022

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

@wagnerpereira
Copy link
Author

@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.

cypress-io/cypress#7062

I'm still searching to find why this is happening.

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

2 participants