def _load_response(response):
 try:
  data = json.loads(response.text)
 except ValueError:
  data = response.text
 ret = {'code': response.status_code, 'content': data}
 return ret

def _load_response ( response ) : try : data = json . loads ( response . text ) except ValueError : data = response . text ret = { 'code' : response . status_code , 'content' : data } return ret
load the response from json data .