-
Notifications
You must be signed in to change notification settings - Fork 649
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
Unused message properties are being defaulted #189
Comments
I didn't notice it in the documentation, thanks, @murgatroid99. I'll wait for the new package then. |
The new |
Hey, @nicolasnoble, thanks for the notice. However, when I try to apply the package definition as in the example within Typescript code, I get a type definition error:
|
We've published version 1.11.1 which includes those definitions in the TypeScript types file. |
Hmm, I updated to version
|
This is fixed with #307 but not released yet |
I fixed the typings locally in order to perform tests. |
@respinha-ribeiro there's an issue with node 10 (nodejs/node#20258) that prevents us from running tests with node 10 at the moment, so we can't legitimately recommend using node 10 with gRPC just yet. This will require a new release of node 10. |
Thank you for the notice. We are using Node 9 anyway and it all seems fine. |
Hello.
If I send a message via gRPC which doesn't have all of its properties set, they are being defaulted to a null/empty value. I've modified the officially provided example to simulate this issue.
I included some more properties in the
HelloReply
messageand I just added a small print statement to
dynamic_codegen/greeter_client.js
and it prints:
So, all properties are being defaulted to 0/""/[]/null. Is this the expected behaviour? I thought it could also be a protobuf.js-specific issue.
In my case, this behaviour is not desirable as in some cases I override existing data in my system with data from protobuf messages and if those properties are defaulted I might even override valid data with a null or empty value.
If this is the expected workflow for gRPC messages, can it be turned off?
The text was updated successfully, but these errors were encountered: