Closed ak-em1603 closed 2 years ago
Aha that's interesting..
I wonder what's the output if you run the following command?
echo 'test' | protoc-gen-grpc-web
Expected output:
protoc-gen-grpc-web: protoc sent unparseable request to plugin.
I get the same output as mentioned by you.
Just to add more on this. I have tried the setup on three differnt platform :- Mac M1, Docker and Ubuntu. The behaviour is consistent for all three setup. The "ee_grpc_web_pb.js" file is not being generated.
Any updates?
Hey sorry for delay.
To help narrow down the issue (between local env issue or with your specific proto files), could you try following the hello world example codegen commands and see if they work for you?
http://google3/javascript/net/grpc/web/streambodyclientreadablestream.js;l=326;rcl=478391678
thanks 😃
And if it is specific to your proto file, could you provide the content and directory structure of your files? Thanks!
This was a silly mistake on my part. The proto file definition had no service defined hence the gprc_web_out files were not generated. Closing this issue
Aha no worries. glad it's working now :)
I am trying to generate codegen files for javascript using following command inside a docker image:-
protoc -I=proto_dir ee.proto --js_out=import_style=commonjs:proto_gen_dir/js --grpc-web_out=import_style=commonjs,mode=grpcwebtext:proto_gen_dir/js
It only generates "ee_pb.js" file and does not generate "ee_grpc_web_pb.js" file. The command does not throw any error.
The protoc is installed using following command. The version 3.20.1 is used due to some issue in generating js-out files:
The proto-gen-grpc-web plugin is installed using following commands:-
proto-gen-grpc-web is on the PATH.
can anyone let me know as to what is the issue here?