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

fix(builtin): rerun yarn_install and npm_install when node version changes #1866

Merged
merged 1 commit into from
May 5, 2020

Conversation

gregmagolan
Copy link
Collaborator

@gregmagolan gregmagolan commented May 5, 2020

Also always symlink package.json and lock file and copy over data files to ensure that yarn_install and npm_install rerun when any of these change and to ensure that all of the labels passed to data are evaluated by Bazel to ensure they are regular files. A typo in a label is a very easy error to make as the label must be //:patches/jest-haste-map+25.3.0.patch and not //patches:jest-haste-map+25.3.0.patch for example if //patches is not a package. With this fix, Bazel will check that the labels passed to data are valid.

Fixes #1712
Fixes #1714
Fixes #1311
Fixes #1601

…anges

Also always symlink package.json and lock file and copy over data files to ensure that yarn_install and npm_install rerun when any of these change and to ensure that all of the labels passed to `data` are evaluated by Bazel to ensure they are regular files. A typo in a label is a very easy error to make as the label must be `//:patches/jest-haste-map+25.3.0.patch` and not `//patches:jest-haste-map+25.3.0.patch` for example if `//patches` is not a package. With this fix, Bazel will check that the labels passed to `data` are valid.
Copy link
Collaborator

@alexeagle alexeagle left a comment

Choose a reason for hiding this comment

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

sweet, nice fix!

it's interesting that you need a marker file to invalidate the repo rule, when node & yarn binaries are passed to it. I guess the model of inputs to an action doesn't match how repo rules are able to access toolchain bits

@alexeagle alexeagle merged commit 8c1e035 into bazel-contrib:master May 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants