HTTP 400: Log response body when it can't be decoded as json

This commit is contained in:
Odd Stråbø 2020-11-25 11:54:22 +01:00
parent 8a9b69f2f5
commit 146bd401bf

View file

@ -141,7 +141,7 @@ class HTTP(object):
try:
LOG.warning(r.json())
except Exception:
pass
LOG.warning(r.text)
elif r.status_code == 500: # log and ignore.
LOG.error("--[ 500 response ] %s", error)