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
[Reopened] Incorrect json serialization of empty StringValue #6667
Comments
Anyone can take a look at this issue? We've heard aa bunch of people that are having the same issue and had to switch to a different library. Thanks! |
Does changing |
Seems the problem is because the array constructor with StringValue has some problems. |
No it's just type checking and changing it does not have any impact on functionality
unfortunately not. we faced this issue on serializing GRPC service response(message structure is similar to my example) |
Fixed in #6713 |
* Initialize well known type values Also fixes #6667 * Revert unwanted change
* Initialize well known type values Also fixes protocolbuffers#6667 * Revert unwanted change
What version of protobuf and what language are you using?
Version: v3.9.1.
Language: PHP 7.3
What operating system (Linux, Windows, ...) and version?
Linux
What did you do?
I have a message defined as following:
What did you expect to see
When converting this message to json string like:
should return:
What did you see instead?
that results in
Syntax error
after applyingjson_decode
Anything else we should know about your project / environment
I'm using c extension, however php package does not have this issue.
Detailed example with tests and docker file https://github.com/serhiikushch/protobuf-issue
The text was updated successfully, but these errors were encountered: