Skip to content
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

[Build] Protobuf version selected by bazel doesn't compile #44239

Closed
waarmond opened this issue Mar 22, 2024 · 3 comments
Closed

[Build] Protobuf version selected by bazel doesn't compile #44239

waarmond opened this issue Mar 22, 2024 · 3 comments
Labels
bug Something that is supposed to be working; but isn't triage Needs triage (eg: priority, bug/not-bug, and owning component)

Comments

@waarmond
Copy link

waarmond commented Mar 22, 2024

What happened + What you expected to happen

My distro uses protobuf 25.3

Ray's bazel selects 3.19.6 which always fails:

ERROR: [bazel-cache]/external/com_google_protobuf/src/google/protobuf/BUILD.bazel:129:8: @@com_google_protobuf//src/google/protobuf:gen_wkt_cc_sources: no such attribute 'exec_tools' in 'genrule' rule (did you mean 'executable'?)
INFO: Repository go_sdk instantiated at:
  /ray/src/ray/WORKSPACE:17:16: in <toplevel>
  ./external/com_github_grpc_grpc/bazel/grpc_extra_deps.bzl:56:27: in grpc_extra_deps
  ./external/io_bazel_rules_go/go/private/sdk.bzl:453:28: in go_register_toolchains
  ./external/io_bazel_rules_go/go/private/sdk.bzl:129:21: in go_download_sdk
Repository rule _go_download_sdk defined at:
  ./external/io_bazel_rules_go/go/private/sdk.bzl:116:35: in <toplevel>
INFO: Repository protobuf~3.19.6 instantiated at:
  <builtin>: in <toplevel>
Repository rule http_archive defined at:
  ./external/bazel_tools/tools/build_defs/repo/http.bzl:381:31: in <toplevel>
ERROR: ./external/com_google_protobuf/BUILD.bazel:82:6: Target '@@com_google_protobuf//src/google/protobuf:wrappers_proto' contains an error and its package is in error and referenced by '@@com_google_protobuf//:wrappers_proto'

How may I force to use system protobuf instead of the vendored version?

May be caused by bazelbuild/bazel#19132

Versions / Dependencies

Python 3.10
Linux main 6.8.0
bazel 7.0.2

Next try with bazel 5.4.1 - Abseil problems:

Compiling absl/debugging/internal/vdso_support.cc [for host] failed: (Exit 1): gcc failed: error executing command 
  (cd ./sandbox/linux-sandbox/2/execroot/com_github_ray_project_ray && \

Compiling absl/debugging/internal/address_is_readable.cc [for host] failed: (Exit 1): gcc failed: error executing command 

Compiling absl/time/internal/cctz/src/time_zone_format.cc [for host] failed: (Exit 1): gcc failed: error executing command 

 Compiling absl/debugging/internal/demangle.cc [for host] failed: (Exit 1): gcc failed: error executing command 

Reproduction script

python -m build --wheel --no-isolation

Issue Severity

High: It blocks me from completing my task.

@waarmond waarmond added bug Something that is supposed to be working; but isn't triage Needs triage (eg: priority, bug/not-bug, and owning component) labels Mar 22, 2024
@mattip
Copy link
Contributor

mattip commented May 14, 2024

There is no current plan for ray to support bazel>5, see #31504 (comment), and newer protobuf requires bazel>5

@waarmond
Copy link
Author

waarmond commented May 23, 2024

I've compiled protobuf 3.18 (/usr/bin/protoc3.18) in parallel to my distro's version.

Now its: src/main/tools/linux-sandbox-pid1.cc:487: "execvp(/usr/lib/ccache/bin/gcc, 0x558ce0d34340)": No such file or directory

Giving bazel the ccache it demands: ccache: error: Failed to create directory /home/me/.ccache/tmp: Read-only file system
bazelbuild/bazel#12124 !

@aslonnie
Copy link
Collaborator

bazel used by ray is upgraded to 6. we are also hard-pinning the bazel version now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something that is supposed to be working; but isn't triage Needs triage (eg: priority, bug/not-bug, and owning component)
Projects
None yet
Development

No branches or pull requests

3 participants