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

Retry start Sauce Connect #219

Merged

Conversation

christian-bromann
Copy link
Contributor

@christian-bromann christian-bromann commented Oct 8, 2020

Someone reported an issue of Sauce Connect launcher failing with ENOENT which is normally impossible because we download Sauce Connect before we run it. It seems that there is a race condition where checking if the Sauce Connect binary was downloaded fails when looking for the version. The execution happens as follows:

  1. check if the binary was downloaded
  2. if no -> download
  3. if yes continue
  4. check if version is the one that has been downloaded
  5. if no -> download expected version
  6. if yes finish

The race condition seem to happen when the check if the binary exists was successful but then the consecutive version check fails if in between someone cleaned the binary which can happen in an CI/CD environment where dependencies are shared.

This patch introduces a retry to see if this race condition can be caught.

Copy link
Collaborator

@wswebcreation wswebcreation left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@wswebcreation wswebcreation merged commit 5ff8838 into karma-runner:master Oct 19, 2020
@karmarunnerbot
Copy link
Member

🎉 This PR is included in version 4.1.6 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants