-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
bazel: issue with cockroachdb/errors
patch applied during Bazel build process
#64299
Comments
@knz When you get a moment, can you help debug by doing the following after you reproduce the failure:
|
Oh, also, is there anything in your |
the file doesn't exist
|
As you can see, my original |
Here's another behavior I had noticed earlier, which I didn't think was relevant, but maybe it is (you tell me) When I run --- a/BUILD.bazel
+++ b/BUILD.bazel
@@ -1,3 +1,5 @@
+load("@rules_proto//proto:defs.bzl", "proto_library")
+load("@io_bazel_rules_go//proto:def.bzl", "go_proto_library")
load("@bazel_gazelle//:def.bzl", "gazelle")
# The following directives inform gazelle how to auto-generate BUILD.bazel
@@ -199,3 +201,17 @@ gazelle(
exports_files([
"TEAMS.yaml",
])
+
+proto_library(
+ name = "profile_proto",
+ srcs = ["all.proto"],
+ visibility = ["//visibility:public"],
+)
+
+go_proto_library(
+ name = "profile_go_proto",
+ compilers = ["//pkg/cmd/protoc-gen-gogoroach:protoc-gen-gogoroach_grpc_compiler"],
+ importpath = "github.com/cockroachdb/cockroach",
+ proto = ":profile_proto",
+ visibility = ["//visibility:public"],
+) I think this latter behavior started to happen at some point after I upgraded bazel, but I am not sure. It doesn't seem to impact the issue we're studying (i.e. my |
FYI I just tried downgrading from bazel 4.0.0 to 3.7.0, and it didn't change any of the symptoms above. |
My
Hmm. This shouldn't happen unless there's a file |
Can you cleanly
|
Aha! the clone was fresh but the working directory wasn't. It was indeed I will now try your patch fix next. |
Ok the build doesn't fail because of the patch any more. I'll send a PR your way. |
64330: bazel: tweak patch we apply to `cockroachdb/errors` r=rail a=rickystewart This patch became outdated as a result of a Gazelle upgrade. Resolves #64299. Release note: None Co-authored-by: Ricky Stewart <[email protected]>
@knz reported the following error in #61913:
Not sure if this is unique to FreeBSD and its
patch
, or if there's an issue withBUILD
file generation I haven't seen.The text was updated successfully, but these errors were encountered: