-
Notifications
You must be signed in to change notification settings - Fork 61
Open
Description
When I generate code from two proto files
// data.proto
syntax = "proto3";
import "ok.proto";
service Data {
rpc create(SetDataRequest) returns (ok.Response);
}
message SetDataRequest {
string uuid = 1;
}// ok.proto
syntax = "proto3";
package ok;
message Response { }With one protoc execute
protoc --proto_path=. --ruby_out=. --twirp_ruby_out=. --plugin=/Users/a.zimin/go/bin/protoc-gen-twirp_ruby data.proto ok.protoI have a code with a missing module name of Response class
# data_twirp.rb
# Code generated by protoc-gen-twirp_ruby 1.4.1, DO NOT EDIT.
# ...SKIP...
rpc :create, SetDataRequest, Response, :ruby_method => :create
# ...SKIP...module Ok
Response = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("ok.Response").msgclass
endWith two protoc calls
protoc --proto_path=. --ruby_out=. --twirp_ruby_out=. --plugin=/Users/a.zimin/go/bin/protoc-gen-twirp_ruby data.proto
protoc --proto_path=. --ruby_out=. --twirp_ruby_out=. --plugin=/Users/a.zimin/go/bin/protoc-gen-twirp_ruby ok.protoGenerated code is correct
# data_twirp.rb
# ...SKIP...
rpc :create, SetDataRequest, Ok::Response, :ruby_method => :create
# ...SKIP...woto, uno4ki and angristan
Metadata
Metadata
Assignees
Labels
No labels