Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for proto3 field presence #3629

Closed
stanley-cheung opened this issue May 20, 2020 · 5 comments · Fixed by #3752
Closed

Support for proto3 field presence #3629

stanley-cheung opened this issue May 20, 2020 · 5 comments · Fixed by #3752
Assignees

Comments

@stanley-cheung
Copy link
Contributor

Proto3 introduced the optional syntax to support field presence tracking in release 3.12.0. We need to add support in our grpc protoc plugin.

See this doc for more details. Basically we need to add a function GetSupportedFeatures() to our grpc protoc plugin to mark our compliance.

Please plan to do this in the next release. If not, please let me know. Thanks!

@stanley-cheung
Copy link
Contributor Author

FYI, grpc/grpc PR: grpc/grpc#22998

@menghanl
Copy link
Contributor

Is this for the proto messages or grpc stubs?
If for proto messages, https://github.com/protocolbuffers/protobuf-go would be the repo for it.

@stanley-cheung
Copy link
Contributor Author

stanley-cheung commented May 21, 2020

This is for grpc stubs. The proto3 'optional' feature won't directly affect us because we are not generating classes for messages. But, we still need to add that GetSupportedFeatures() function in our grpc plugin to mark compliance. This is asked for by the protobuf team.

@dfawley
Copy link
Member

dfawley commented Dec 1, 2020

@mt-inside

code generator protoc-gen-gogo hasn't been updated to support optional fields in proto3
...
I installed protoc-gen-gogo just now, with go get -u github.com/gogo/protobuf/protoc-gen-gogo

You should file this in the gogo proto repo (github.com/gogo/protobuf) instead.

@mt-inside
Copy link

Oh wow sorry, I've literally pasted this into the wrong brower tab.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 31, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants