Hey folks, I'm having trouble building mainline Pa...
# development
c
Hey folks, I'm having trouble building mainline Pants:
Copy code
error: failed to run custom build command for `protos v0.0.1 ($pantsdir/src/rust/engine/protos)`

Caused by:
  process didn't exit successfully: `$pantsdir/src/rust/engine/target/debug/build/protos-e2c47360b0048589/build-script-build` (exit status: 1)
  --- stdout
  cargo:rerun-if-changed=protos/bazelbuild_remote-apis/build/bazel/remote/execution/v2/remote_execution.proto
  cargo:rerun-if-changed=protos/bazelbuild_remote-apis/build/bazel/semver/semver.proto
  cargo:rerun-if-changed=protos/buildbarn/cas.proto
  cargo:rerun-if-changed=protos/googleapis/google/bytestream/bytestream.proto
  cargo:rerun-if-changed=protos/googleapis/google/rpc/code.proto
  cargo:rerun-if-changed=protos/googleapis/google/rpc/error_details.proto
  cargo:rerun-if-changed=protos/googleapis/google/rpc/status.proto
  cargo:rerun-if-changed=protos/googleapis/google/longrunning/operations.proto
  cargo:rerun-if-changed=protos/pants/cache.proto
  cargo:rerun-if-changed=protos/standard/google/protobuf/empty.proto
  cargo:rerun-if-changed=protos/bazelbuild_remote-apis
  cargo:rerun-if-changed=protos/buildbarn
  cargo:rerun-if-changed=protos/googleapis
  cargo:rerun-if-changed=protos/pants
  cargo:rerun-if-changed=protos/standard

  --- stderr
  Error: Custom { kind: Other, error: "protoc failed: google/bytestream/bytestream.proto:20:1: warning: Import google/protobuf/wrappers.proto is unused.\ngoogle/bytestream/bytestream.proto:19:1: warning: Import google/api/annotations.proto is unused.\ncache.proto: This file contains proto3 optional fields, but --experimental_allow_proto3_optional was not set.\n" }
warning: build failed, waiting for other jobs to finish...
protoc version is "libprotoc 3.12.4", OS is Ubuntu 22.04.4 LTS . Anyone have any pointers?
2
w
Silly question, is this the same problem if you build in release mode?
Also, isn't that an ancient protoc? Or is that just default Ubuntu 22?
f
we use protoc v23.x on CI
3.12.4 is from 2020
👀 1
I suggest upgrading protoc
c
it's default on ubuntu 22, maybe it's time to upgrade lol. It does build fine in release mode!
w
@careful-address-89803 DId that work for you?
p
Thank you! I too was using the ubuntu default 3.12.4. I updated to 23.4 (installed in ~/.local) and now I can build pants again 🙂.
👍 1
c
yep, works now. Thanks!
👍 2