sonnet icon indicating copy to clipboard operation
sonnet copied to clipboard

Build with bazel 0.27 fails

Open timokau opened this issue 5 years ago • 3 comments

The build fails due to protobuf:

DEBUG: Call stack for the definition of repository 'com_google_protobuf' which is a git_repository (rule definition at /build/output/external/bazel_tools/tools/build_defs/repo/git.bzl:252:18):
 - /build/source/WORKSPACE:5:1
ERROR: /build/output/external/com_google_protobuf/protobuf.bzl:130:19: Traceback (most recent call last):
        File "/build/output/external/com_google_protobuf/protobuf.bzl", line 125
                rule(attrs = {"srcs": attr.label_list...()}, <2 more arguments>)
        File "/build/output/external/com_google_protobuf/protobuf.bzl", line 130, in rule
                attr.label(cfg = "host", executable = True, sin..., ...)
'single_file' is no longer supported. use allow_single_file instead. You can use --incompatible_disable_deprecated_attr_params=false to temporarily disable this check.

This will be fixed upstream by https://github.com/protocolbuffers/protobuf/pull/6304, so sonnets protobuf version should be updated after that is merged.

timokau avatar Jun 26 '19 10:06 timokau

My fix there is for protobuf lite. As far as I can see sonnet uses normal protobuf which already has the fix since this commit https://github.com/protocolbuffers/protobuf/commit/d5f0dac497f833d06f92d246431f4f2f42509e04

Available in master or v3.9.0-rc1. Good luck!

codesuki avatar Jun 26 '19 22:06 codesuki

Thanks for pointing it out! This will be fixed in the next release.

diegolascasas avatar Jul 04 '19 17:07 diegolascasas

Just an update, we decided to postpone the update until version 3.9 is released. Meanwhile you should set --incompatible_disable_deprecated_attr_params=false if you are building with bazel. I will leave this issue open for now.

diegolascasas avatar Jul 05 '19 15:07 diegolascasas