When running Codegen on a proto file that relies on google's well known types (eg: google.protobuf.Timestamp / import "google/protobuf/timestamp.proto"), an error is thrown:
thread 'main' panicked at 'Gen code failed.: Custom { kind: Other, error: "protobuf path \"google/protobuf/timestamp.proto\" is not found in import path [\"src/protocols/protos\"]" }', build.rs:35:10
It appears this is because ttrpc_compiler::codegen isn't aware of these types, so it has trouble parsing the proto file.
However, protobuf_codegen, which is responsible for generating the message classes handles the well known types without any problems. I suspect ttrpc_compiler doesn't actually need to know about the common types as it seems to be mostly interested in generating the RPC stubs.
When running
Codegen
on a proto file that relies on google's well known types (eg:google.protobuf.Timestamp
/import "google/protobuf/timestamp.proto"
), an error is thrown:It appears this is because
ttrpc_compiler::codegen
isn't aware of these types, so it has trouble parsing the proto file. However,protobuf_codegen
, which is responsible for generating the message classes handles the well known types without any problems. I suspectttrpc_compiler
doesn't actually need to know about the common types as it seems to be mostly interested in generating the RPC stubs.