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

Fix the method name clashes for generated commonjs files #362

Merged
merged 1 commit into from
Nov 9, 2018
Merged

Fix the method name clashes for generated commonjs files #362

merged 1 commit into from
Nov 9, 2018

Conversation

weilip1803
Copy link

@weilip1803 weilip1803 commented Nov 9, 2018

This PR fixes #346.
When same the same proto file defines the same service name twice.

Example - test.proto

service Random
{
    rpc echo(google.protobuf.Empty) returns (stream SomeMessage) {}
}
service Random2
{
    rpc echo(google.protobuf.Empty) returns (stream SomeMessageTwo) {}
}

It will define the below method twice in the grpc_web_pb.js files which cause a error on run time

const methodInfo_echo = new grpc ....... 

Copy link
Collaborator

@stanley-cheung stanley-cheung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix!

@stanley-cheung stanley-cheung merged commit f28d6cb into grpc:master Nov 9, 2018
loyalpartner pushed a commit to loyalpartner/grpc-web that referenced this pull request Sep 4, 2020
This commit makes websocket_wrapper.go file consistent with the changes
in grpc_web_response.go file, PR grpc#359.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants