-
Notifications
You must be signed in to change notification settings - Fork 96
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
Rename target_compatible_with to internal_target_compatible_with in _rbe_config #913
Conversation
I tried to test this change in a few ways, but I can't seem to make bazel not throw some kind of unrelated error. So I'm hoping that buildkite will tell me if I messed something up. My apologies. On a related note, it looks like bazel imports version 3.1.0 of this repo. So the patch that I tested within the bazel repos actually looks differently than what you see in the PR here. The 3.1.0 version of this patch: diff --git a/rules/rbe_repo.bzl b/rules/rbe_repo.bzl
index a386010..faec7e6 100644
--- a/rules/rbe_repo.bzl
+++ b/rules/rbe_repo.bzl
@@ -817,7 +817,7 @@ _rbe_autoconfig = repository_rule(
"tag": attr.string(
doc = ("Optional. The tag of the image to pull, e.g. latest."),
),
- "target_compatible_with": attr.string_list(
+ "internal_target_compatible_with": attr.string_list(
default = _RBE_UBUNTU_TARGET_COMPAT_WITH,
doc = ("The list of constraints that will be added to the " +
"toolchain in its target_compatible_with attribute. For " +
@@ -1174,7 +1174,7 @@ def rbe_autoconfig(
registry = registry,
repository = repository,
tag = tag,
- target_compatible_with = target_compatible_with,
+ internal_target_compatible_with = target_compatible_with,
use_checked_in_confs = use_checked_in_confs,
use_legacy_platform_definition = use_legacy_platform_definition,
) |
The upcoming Incompatible Target Skipping patch (bazelbuild#10945) introduces a new `target_compatible_with` attribute which clashes with one of the custom attributes in the bazel-toolchains repo. This patch fixes the clash so we can merge the Incompatible Target Skipping path. This is essentially a backport of bazelbuild/bazel-toolchains#913.
The upcoming Incompatible Target Skipping patch (bazelbuild#10945) introduces a new `target_compatible_with` attribute which clashes with one of the custom attributes in the bazel-toolchains repo. This patch fixes the clash so we can merge the Incompatible Target Skipping path. This is essentially a backport of bazelbuild/bazel-toolchains#913.
The upcoming Incompatible Target Skipping patch (#10945) introduces a new `target_compatible_with` attribute which clashes with one of the custom attributes in the bazel-toolchains repo. This patch fixes the clash so we can merge the Incompatible Target Skipping path. This is essentially a backport of bazelbuild/bazel-toolchains#913.
…rbe_config This essentially the same patch as 9a2fbe2 except that it deals with `target_compatible_with` instead of `exec_properties`. The PR bazelbuild/bazel#10945 adds a new `target_compatible_with` attribute to all rules. That includes repository rules. Currently the patch fails in `//src/test/shell/bazel:bazel_bootstrap_distfile_test`. The error complains about: Error in repository_rule: There is already a built-in attribute 'target_compatible_with' which cannot be overridden Since the repository rule is abstracted by a macro, it should be fairly safe to rename the attribute to `internal_target_compatible_with`.
b7b7e80
to
4ab93cf
Compare
This last push is a rebase. |
Now that @katre fixed Incompatible Target Skipping via bazelbuild/bazel#12378, we don't need this patch anymore. |
This essentially the same patch as
9a2fbe2 except that it deals with
target_compatible_with
instead ofexec_properties
.The PR bazelbuild/bazel#10945 adds a new
target_compatible_with
attribute to all rules. That includes repository rules. Currently the
patch fails in
//src/test/shell/bazel:bazel_bootstrap_distfile_test
.The error complains about:
Since the repository rule is abstracted by a macro, it should be
fairly safe to rename the attribute to
internal_target_compatible_with
.