Giter Site home page Giter Site logo

Comments (5)

yugui avatar yugui commented on May 2, 2024 1

Can't reproduce.

Another possible guess is that your protoc-gen-go is out-of-date. What happens if you run go get -u github.com/golang/protobuf/protoc-gen-go then try it again?

from grpc-gateway.

yugui avatar yugui commented on May 2, 2024

I guess the revision of google.golang.org/grpc you have is inconsistent to the example.
Could you try running go get -u google.golang.org/grpc to update the revision?

from grpc-gateway.

diogomonica avatar diogomonica commented on May 2, 2024

I'm on 0e69ad1, so latest master.

from grpc-gateway.

diogomonica avatar diogomonica commented on May 2, 2024

It seems to build now. Probably screwed up along somewhere. Thank you.

from grpc-gateway.

diogomonica avatar diogomonica commented on May 2, 2024

The generated protos that are currently in the repository work, but when regenerating using the instructions:

➜ protoc -I/usr/local/include -I. \
 -I$GOPATH/src \     
 -I$GOPATH/src/github.com/gengo/grpc-gateway/third_party/googleapis \
 --go_out=Mgoogle/api/annotations.proto=github.com/gengo/grpc-gateway/third_party/googleapis/google/api,plugins=grpc:. echo_service.proto
➜ protoc -I/usr/local/include -I. \
 -I$GOPATH/src \     
 -I$GOPATH/src/github.com/gengo/grpc-gateway/third_party/googleapis \
 --grpc-gateway_out=logtostderr=true:. echo_service.proto

Using protoc:

➜  protoc --version
libprotoc 3.0.0

And with go-grpc on 0e69ad1 (master) from 9 hours ago, and grpc-gateway on 67e1374 (master), I still get:

➜  go build 
# github.com/gengo/grpc-gateway/examples/examplepb
examplepb/echo_service.pb.go:114: cannot use _EchoService_Echo_Handler (type func(interface {}, context.Context, grpc.Codec, []byte) (interface {}, error)) as type grpc.methodHandler in field value
examplepb/echo_service.pb.go:118: cannot use _EchoService_EchoBody_Handler (type func(interface {}, context.Context, grpc.Codec, []byte) (interface {}, error)) as type grpc.methodHandler in field value

from grpc-gateway.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.