We are getting errors from the Druid APIs but it is in a bytes format b''. When the error response passed to the json.loads() it will crash. I think this happening after this PR #121.
Error Details
except urllib.error.HTTPError as e:
err = e.read()
if e.code == 500:
# has Druid returned an error?
try:
err = json.loads(err) # ERROR HAPPEN HERE
except ValueError:
if HTML_ERROR.search(err):
err = HTML_ERROR.search(err).group(1)
except (ValueError, AttributeError, KeyError):
pass
err = b'{"error":"Unknown exception","errorMessage":"Failure getting results for query[85d259df-c0ea-43c7-93d9-49e609b3b203] url[http://druid/druid/v2/] because of [org.jboss.netty.channel.ChannelException: Channel disconnected]","errorClass":"org.apache.druid.java.util.common.RE","host":null}'
Overview
We are getting errors from the Druid APIs but it is in a bytes format
b''
. When the error response passed to thejson.loads()
it will crash. I think this happening after this PR #121.Error Details
versions