RE: [protobuf] Parsing of .desc fails for message with custom option

2021-02-12 Thread Marc Schafer
Thank you for the pointers Adam. The string did not match the file on disk because I neglected to open the file in binary mode. Commenting out the custom option coincidentally made everything work leading me down the rat hole but the real fix is to open in binary mode and then everything works. 

Re: [protobuf] Parsing of .desc fails for message with custom option

2021-02-12 Thread 'Adam Cozzette' via Protocol Buffers
I don't think this necessarily has anything to do with the custom option. FileDescriptorSet is itself just a protocol buffer message, so parsing it doesn't involve interpreting the meaning of its contents. It's just like parsing any other proto, so if it's failing then either the descriptors were

RE: [protobuf] Parsing of .desc fails for message with custom option

2021-02-12 Thread Marc Schafer
I am invoking protoc –descriptor_set_out on the .proto file with contents described below that include the definition of the custom option. I’m not sure what else you are suggesting I include. I attached the .proto file to clarify the reproduction steps.protoc –descriptor_set_out simple.proto Use