blob: 682e51aaa694dd9a0eaf3d1f62bd372fdf4ed0ea [file] [log] [blame]
#!/usr/bin/env python
"""
Read adapter data while decoding both known custom fields
"""
import sys
from json import dumps
from common.utils.json_format import MessageToDict
from voltha.protos import adapter_pb2
adapter = adapter_pb2.Adapter()
binary = sys.stdin.read()
adapter.ParseFromString(binary)
print dumps(MessageToDict(adapter, strict_any_handling=False))