You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a bit of an awkward vendoring setup where we want to copy remote protocol buffer files to the local source tree and commit the generated Go alongside it (so the repository can be built via go build). This mostly works fine, except I occasionally see (apparently) spurious test failures when using RBE to build the test. Specifically, I see:
INFO: From Testing //third_party/bazel:proto_srcs_sync_test:
==================== Test output for //third_party/bazel:proto_srcs_sync_test:
ERROR: cannot compare a directory "third_party/bazel/proto_srcs" against a file "third_party/bazel/src"
================================================================================
The test runs fine if built locally (surviving even a bazel clean) and when manually inspecting the files in question in the execroot, both appear to be directories and not files.
Version
Development (host) and target OS/architectures:
Debian rodete-based Linux distribution
Output of bazel --version: bazel 6.2.0
Version of the Aspect rules, or other relevant rules from your WORKSPACE or MODULE.bazel file:
It's really (frustatingly) inconsistent. I have nearly identical setup for Rust protobufs that has never exhibited the behavior. But the BUILD snippet which causes problems is:copy_to_directory( name = "proto_srcs", srcs = [ # We need to include the Gazelle-generated BUILD files in the original bundle to avoid test failures. "//third_party/bazel/src/main/java/com/google/devtools/build/lib/buildeventstream/proto:BUILD", "//third_party/bazel/src/main/java/com/google/devtools/build/lib/packages/metrics:BUILD", "//third_party/bazel/src/main/protobuf:BUILD", "@io_bazel_files//:proto_srcs", ], include_external_repositories = ["io_bazel_files"], replace_prefixes = { "src/": "", "third_party/bazel/": "", }, visibility = ["//visibility:private"],)write_source_file( name = "proto_srcs_sync", in_file = ":proto_srcs", out_file = "src", visibility = ["//visibility:private"],)
### Any other information?
_No response_
The text was updated successfully, but these errors were encountered:
What happened?
I have a bit of an awkward vendoring setup where we want to copy remote protocol buffer files to the local source tree and commit the generated Go alongside it (so the repository can be built via
go build
). This mostly works fine, except I occasionally see (apparently) spurious test failures when using RBE to build the test. Specifically, I see:The test runs fine if built locally (surviving even a
bazel clean
) and when manually inspecting the files in question in the execroot, both appear to be directories and not files.Version
Development (host) and target OS/architectures:
Debian rodete-based Linux distribution
Output of
bazel --version
: bazel 6.2.0Version of the Aspect rules, or other relevant rules from your
WORKSPACE
orMODULE.bazel
file:Language(s) and/or frameworks involved:
How to reproduce
The text was updated successfully, but these errors were encountered: