Closed ozio85 closed 4 years ago
I have tested this on 0.26 and 1.2.0 and both fail when using rules_cc instead of built in native rules if your project also uses tags. I thought perhaps mutability had changed over time, but I don't think this line ever worked. @oquenchil @hlopko?
You will have to include a later commit of rules_cc
http_archive(
name = "rules_cc",
sha256 = "e75dfb05bc1e89ebbb6696cadb5e455833690009310d9dc5512151c5adb0e4e3",
strip_prefix = "rules_cc-cfe68f6bc79dea602f2f6a767797f94a5904997f",
urls = [ "https://github.com/bazelbuild/rules_cc/archive/cfe68f6bc79dea602f2f6a767797f94a5904997f.zip",
],
)
Is this still a problem?
load("@rules_cc//cc:defs.bzl", "cc_binary")
cc_binary(
name = "cc",
srcs = ["cc.cc"],
tags = ["tag"],
)
Seems to work alright.
Description of the problem / feature request:
Problem occurs if a tag is already used in a rule: File "D:/build/j4jghgxg/external/rules_cc/cc/defs.bzl", line 21, in _add_tags attrs["tags"] += [_MIGRATION_TAG] trying to mutate a frozen object
I guess it is not ready to use yet, but this seems like a bug anyway
Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
Use rules_cc with a rule with existing "tags"
What operating system are you running Bazel on?
0.29.1
What version of rules_cc do you use? Can you paste the workspace rule used to fetch rules_cc? What other relevant dependencies does your project have?
0d5f3f2768c6ca2faca0079a997a97ce22997a0c
Have you found anything relevant by searching the web?
Nope :)