newbie here.
Currently learning how grpc works and was going through the tutorial in this link
https://grpc.io/docs/quickstart/go.html#update-and-run-the-application
When I ran the example using the helloworld.pb.go
file provided, it works. But when I deleted that file and ran protoc --go_out=plugins=grpc:. *.proto
to generate the that file again, I find that I can no longer run the greeter server.
The error I am getting is
google.golang.org/grpc/examples/helloworld/helloworld helloworld/helloworld.pb.go:105:11: cannot use _Greeter_SayHello_Handler (type func(interface {}, "context".Context, grpc.Codec, []byte) (interface {}, error)) as type grpc.methodHandler in field value
Tried to google but couldn't find out why. My protobuf version is 3.5.1 and the grpc is freshly cloned from github.com/golang/protobuf/protoc-gen-go
_Greeter_SayHello_Handler
.Generate the file again using the protoc command. If the signature is different then your protoc-gen-go is mismatched. Delete any binary protoc in your $PATH and install again. – kdvy