GobySoft / goby3

The Goby Underwater Autonomy Project Version 3
Other
24 stars 11 forks source link

Improve Protobuf log plugin #304

Closed tsaubergine closed 1 year ago

tsaubergine commented 1 year ago

Fixes bug where extensions are sometimes not embedded in .goby file (and thus required the extension library to be present for goby_log_tool to decode correctly).

Previously if an extension was only used in a submessage (Message field) of a message, the FileDescriptorProto was not written to the .goby file.

This PR recursively searches the Protobuf message descriptor to add extensions to submessages as well.

Additionally, on the read side, a warning is written to glog if the message is missing any extensions (recursively).