tap: Fix the failure of protobuf to PCAP generation (#28180)
tap: Fix the protobuf to PCAP generation failure When run 'bazel run @envoy_api//tools:tap2pcap path_0.pb path_0.pcap': ... Traceback (most recent call last): File "..../tools/tap2pcap.runfiles/envoy_api/tools/tap2pcap.py", line 88, in <module> tap2pcap(sys.argv[1], sys.argv[2]) File "..../tools/tap2pcap.runfiles/envoy_api/tools/tap2pcap.py", line 53, in tap2pcap wrapper.ParseFromString(f.read()) ^^^^^^^^ File "<frozen codecs>", line 322, in decode UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb8 in position 1: invalid start byte ... The protobuf file is in binary format, opening this file in binary mode will help to generate the PCAP file successfully. Signed-off-by: Haiyue Wang <haiyue.wang@intel.com> Mirrored from https://github.com/envoyproxy/envoy @ c1cae43bed0cd91b423dafa388a370a27cb163e7main
parent
e76c403fc5
commit
50b5cf1c11
1 changed files with 1 additions and 1 deletions
Loading…
Reference in new issue