In integrating a complex 3rd-party gRPC client, I discovered that none of their .proto files have package declarations.
(I've informed them that this is contrary to Protobuf recommendations, but I doubt they will change the API.)
I was able to work around this with Tonic. For any file without a package declared, it seems that tonic_build::compile_protos
puts the output in a file called "_.rs." One issue I ran into was that subsequent tonic_build::compile_protos
calls will overwrite that file, but I got around that by building one proto that import
s the others.
So, I have it working, but I'm worried that there is going to be some unexpected issue down the road. By chance does anyone have any experience with a situation like this?