-
I have a Bazel setup that is using the protoc-gen-connect-go as a plug-in in the go proto compiler. It currently fails but there is zero output. Are there any docs or someone has a few tips how to get some output to see what is going on? The setup was working but we need to change the Go dependencies. Thus, I suspect a missing dependency somewhere. But I don't get a good error message at all. This is how the compiler is defined: go_proto_compiler(
name = "connect_go_proto_compiler",
plugin = "@com_connectrpc_connect//cmd/protoc-gen-connect-go:protoc-gen-connect-go",
suffix = ".connect.go",
options = [
# This is needed so that the package name for the connectrpc generated go file
# matches the package name for the protoc generated go file.
"package_suffix=",
],
visibility = ["//visibility:public"],
deps = ["@com_connectrpc_connect//:go_default_library"],
) The error is:
From testing with an invalid options I do at least know the plug-in is properly called. I would get output such as:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
I figured out what's causing the problem. This prevents generation for some proto files: connect-go/cmd/protoc-gen-connect-go/main.go Lines 141 to 143 in a34cd27 Would it be worth to consider this an error? |
Beta Was this translation helpful? Give feedback.
In a previous version rules_go would generate and empty file if a plug-in did not output anything. In version 0.54.0 this was broken.
bazel-contrib/rules_go#4317