I have an object that I de-serialize using protobuf in Python. When I print the object it looks like a python object, however when I try to convert it to
I'd recommend using protobuf↔json converters from google's protobuf library:
from google.protobuf.json_format import MessageToJson
jsonObj = MessageToJson(org)
Refer to protobuf package API: https://developers.google.com/protocol-buffers/docs/reference/python/ (see module google.protobuf.json_format).
Note you can also serialise the protobuf to a Dict
from google.protobuf.json_format import MessageToDict
dict_obj = MessageToDict(org)