fix: UnicodeDecodeError when request body in protobuf

This commit is contained in:
debugtalk
2020-05-28 14:14:10 +08:00
parent 83286007ab
commit 3e8b906a4c
2 changed files with 2 additions and 1 deletions

View File

@@ -45,7 +45,7 @@ def get_req_resp_record(resp_obj: Response) -> ReqRespData:
request_body = resp_obj.request.body
try:
request_body = json.loads(request_body)
except json.JSONDecodeError:
except (json.JSONDecodeError, UnicodeDecodeError):
pass
if request_body: