radschapur
radschapur

Reputation: 535

Python equivalence of C++ protobuf message differencer

I am trying to compare two protobuf messages in Python for equality, ignoring the order elements in lists and so on.

For C++, I found the MessageDifferencer (https://developers.google.com/protocol-buffers/docs/reference/cpp/google.protobuf.util.message_differencer)

Now I'm looking for something similar in Python, but can't really find anything. Any suggestions what I can use?

Thanks

Upvotes: 13

Views: 2600

Answers (1)

dayfine
dayfine

Reputation: 27

I don't think anything exists. You can probably wrap the C++ implementation in python using CLIF or something similar.

I implemented a version myself (with only basic set of features) in https://github.com/dayfine/proto-matcher

Upvotes: 1

Related Questions