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

getting error on build ci/cd #79

Closed
JustFly1984 opened this issue Mar 19, 2020 · 6 comments
Closed

getting error on build ci/cd #79

JustFly1984 opened this issue Mar 19, 2020 · 6 comments
Labels
question Further information is requested

Comments

@JustFly1984
Copy link

yarn run v1.22.4
$ lockfile-lint --path yarn.lock --allowed-hosts yarn --validate-https
detected invalid host(s) for package: request@cypress-io/request#b5af0d1fa47eec97ba980cde90a13e69a2afcd16
    expected: registry.yarnpkg.com
    actual: codeload.github.com

error: command failed with exit code 1 

error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
##[error]Process completed with exit code 1.

is it false positive? how can I fix it? have tried to clear cache, node_modules and regenerate yarn.lock

Our build pipeline is broken. Please provide an advise.

@lirantal
Copy link
Owner

hmm, interesting. Can you share the lockfile that caused this so we can test?

@lirantal lirantal added bug Something isn't working question Further information is requested and removed bug Something isn't working labels Mar 19, 2020
@lirantal
Copy link
Owner

@JustFly1984 if I have to assume it seems like you have a package there installed from github directly, where as in the hosts you are only allowing packages fetched from the yarn registry mirror. Is this what is happening?

If you wanted to whitelist all of github as a trusted source of packages:

lockfile-lint --path yarn.lock --allowed-hosts yarn github.com --validate-https

@JustFly1984
Copy link
Author

I got the solution, but I do not consider github as safe source of direct dependencies at this moment. The issue is that I would not like dependencies of subdependencies to source from github directly. It is suspicious that cypress has this published in 4.2.0 version. I’ve cross linked issues in cypress repo

@lirantal
Copy link
Owner

So sounds like you indeed found a situation with that dependencies and best to check with the direct parent of it. Can you share the github issue link? I'll be happy to follow up on it and also get the context for it.

@XhmikosR
Copy link
Contributor

cypress-io/cypress#6785

@lirantal I think you can close the issue 🙂

@lirantal
Copy link
Owner

Yes indeed, thanks for the ping @XhmikosR 🙏

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

No branches or pull requests

3 participants