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

Changes in BUILD files of transitive dependencies are not tracked #3459

Closed
arjantop opened this issue Dec 30, 2019 · 0 comments · Fixed by #3460
Closed

Changes in BUILD files of transitive dependencies are not tracked #3459

arjantop opened this issue Dec 30, 2019 · 0 comments · Fixed by #3460

Comments

@arjantop
Copy link
Contributor

arjantop commented Dec 30, 2019

Expected behavior

Skaffold should track changes of transitive BUILD files.

Actual behavior

There is no tracking of transitive BUILD files currently.
Example: Base image defined in build file base/BUILD and usage of this image by go_image in service/BUILD. Changes of base image do not trigger rebuilds and wrong image is cached/tagged.

Information

  • Skaffold version: v1.1.0
  • Operating system: MacOS 10.15.2
  • Bazel version: 1.2.0

Steps to reproduce the behavior

foo/BUILD

genrule(
        name = "foo",
        srcs = [
                "//bar:bar",
        ],
        outs = ["foo.txt"],
        cmd = "cat $(location //bar:bar) > $@",
)

bar/BUILD

genrule(
        name = "bar",
        outs = ["bar.txt"],
        cmd = "echo bar > $@",
        visibility = ["//visibility:public"],
)

Current bazel query: bazel query "kind('source file', deps('//foo:foo')) union buildfiles('//foo:foo')" --noimplicit_deps --order_output=no --output=label
Output:

//foo:BUILD

Fixed bazel query: bazel query "kind('source file', deps('//foo:foo')) union buildfiles(deps('//foo:foo'))" --noimplicit_deps --order_output=no --output=label
Output:

//bar:BUILD
//foo:BUILD
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

Successfully merging a pull request may close this issue.

1 participant