-
Notifications
You must be signed in to change notification settings - Fork 15.6k
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
Fix reflection access when using old generated code #6824
Conversation
(The implementation to fix this is in the following commit.)
FileDescriptor construction uses an extension registry including extensions from imports. If these were created using an older version of protoc, the FieldDescriptor.Extension property may be null; we ignore such extensions rather than failing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
This needs to be backported to 3.10.x as well? |
Ooops it looks like I forgot to trigger the tests (The settings of the protobuf github projects don't enforce that the tests are triggered, which makes it easy to miss that) @rafi-kamal you should add a "Required" test status for one of the test suites (e.g. "Bazel"), that way if tests are not triggered, PR will be unmergeable. |
@rafi-kamal can you check the status of the tests on master and revert if this PR broke anything? |
@jtattermusch: Yes, I suspect this needs to be backported to 3.10.x. Will try to create a PR for that (and the other one) in the next day or two. |
Problem: (OldExtensions2.cs and OldExtensions1.cs) didn't get added to Makefile.am (and I forgot to trigger the tests and merged to soon because I didn't notice that). |
I did add them to Makefile.am - should I have added them in multiple places? |
The proto files were added but not the corresponding generated code. |
Ah, whoops - will create a PR for that later. Doh. |
Fixes #6822.