bazel: ignore tool_deps for dependency validation#17598
bazel: ignore tool_deps for dependency validation#17598keith wants to merge 1 commit intoenvoyproxy:mainfrom
Conversation
When validating the different deps types and their use_categories, host / tool deps don't need to be included since those aren't part of the built product. Signed-off-by: Keith Smiley <keithbsmiley@gmail.com>
|
LGTM but defer to @envoyproxy/dependency-shepherds |
|
LGTM. I know @moderation has some stronger opinions here though. |
|
@keith Not keen on carving some categories of dependencies out of the checks. Feels like a slippery slope. Could a sophisticated adversary somehow introduce problems in the excluded dependencies that then end up impacting the built product? Here is the Bazel documentation - https://docs.bazel.build/versions/4.0.0/user-manual.html#query Is this the error you are trying to work around? #17445 (comment) Is there a way to fix upstream in |
|
This also works: diff --git a/bazel/repository_locations.bzl b/bazel/repository_locations.bzl
index 59ad429af..72cf854d4 100644
--- a/bazel/repository_locations.bzl
+++ b/bazel/repository_locations.bzl
@@ -656,7 +656,7 @@ REPOSITORY_LOCATIONS_SPEC = dict(
strip_prefix = "rules_foreign_cc-{version}",
urls = ["https://github.com/bazelbuild/rules_foreign_cc/archive/{version}.tar.gz"],
release_date = "2021-07-22",
- use_category = ["build"],
+ use_category = ["build", "dataplane_core", "controlplane"],
),
rules_python = dict(
project_name = "Python rules for Bazel", |
|
/wait |
|
With this PR about to be merged can this PR be closed? |
|
Yea I was keeping this open as a placeholder, it might be worth investigating why that connection exists in the non-host parts of the build, but unless it causes more issue I'm not going to look at it for now |
When validating the different deps types and their use_categories, host
/ tool deps don't need to be included since those aren't part of the
built product. We hit this with rules_foreign_cc changes.
Signed-off-by: Keith Smiley keithbsmiley@gmail.com