cockroachdb / cockroachdb/cockroach
bazel: certain targets do not build by themselves, and only build when `embed`'ed into a larger library
- Dominant language
- Go
- Stars
- 32.5k
- Forks
- 4.1k
- PR merge metrics
- PR metrics pending
Description
Some targets (generally `go_proto_library` targetts) do not successfully build by themselves, and need to be `embed`'ed into another target to be built. `pkg/kv/kvserver/closedts/ctpb/service.pb.go` appears to be one of these: note it needs a `String()` method to meet the `Message` interface, but it only gets one from `service.go`. `service.pb.go` can't compile by itself but it is by itself in a build target.
One way to solve this would be to update `go_proto_library` to take an additional list of "extra" source files.
See [internal discussion](https://cockroachlabs.slack.com/archives/CJ0H8Q97C/p1758748814611039?thread_ts=1758708650.450059&cid=CJ0H8Q97C).
Jira issue: CRDB-58748
Contributor guide
Assessment
This issue has not been assessed yet.