prototool icon indicating copy to clipboard operation
prototool copied to clipboard

Update grpcurl dependency to fix breakage caused by protobuf v1.4.0

Open sfllaw opened this issue 4 years ago • 5 comments

Problem

user@host:~/go/src/myprog$ go mod tidy
go: finding module for package github.com/golang/protobuf/jsonpb/jsonpb_test_proto
github.corp.qc/qc/bidding-rate-card-service/internal/gomod imports
        github.com/uber/prototool/cmd/prototool imports
        github.com/uber/prototool/internal/cmd imports
        github.com/uber/prototool/internal/exec imports
        github.com/uber/prototool/internal/grpc imports
        github.com/fullstorydev/grpcurl tested by
        github.com/fullstorydev/grpcurl.test imports
        github.com/golang/protobuf/jsonpb/jsonpb_test_proto: module github.com/golang/protobuf@latest found (v1.4.2), but does not contain package github.com/golang/protobuf/jsonpb/jsonpb_test_proto

This is caused because the v1.3.5 is the last version that contains github.com/golang/protobuf/jsonpb/jsonpb_test_proto. Protobuf v1.4 removed it, which was a backwards-incompatible change.

Solution

fullstorydev/grpcurl#145 fixes the bug, but this requires a change to Prototool’s go.mod to require at least v1.5.1: https://github.com/uber/prototool/blob/a6d064684c011c8482f4218c681a66a64031fb1d/go.mod#L7

I'm not sure if there would be any harmful side-effects to bumping the version requirement. gRPCurl doesn’t force a newer version of protobuf, so things should be OK.

sfllaw avatar Jun 04 '20 22:06 sfllaw

Noted, thanks for this, I'll update this.

sunwen18 avatar Jun 05 '20 13:06 sunwen18

Would it be possible to do a small release with just that change?

AlekSi avatar Jun 25 '20 09:06 AlekSi

@sunwen18 Do you have any updates?

mdreizin avatar Oct 21 '20 11:10 mdreizin

I am needing this fix also

jnvillar avatar Jan 29 '21 13:01 jnvillar

Hi @sunwen18! I'd really like this if you could get some time to roll it :). Thank you!

chapmanc avatar Mar 03 '21 03:03 chapmanc