code: def _handle_response(self, url, res, suppress_empty=True):
          
          self._last_response = res
          result = {}
          if res.status_code in (200, 201, 202):
              try:
                  result = res.json()
              except Exception as e:  # json might be invalid, or store might be down
                  e.message += " (_handle_response failed to decode JSON: " + str(res.content) + ")"
                  raise  # TODO better exception
          elif res.status_code == 204 and not suppress_empty:
              raise EmptyResponseWarning("%d %s @ %s: %s" % (res.status_code, res.reason, url, res.content), res)
          elif res.status_code >= 500:
              raise ServerException("%d %s @ %s: %s" % (res.status_code, res.reason, url, res.content), res)
          elif res.status_code == 429:
              raise RateLimitingException("%d %s @ %s: %s" % (res.status_code, res.reason, url, res.content), res)
          elif res.status_code >= 400:
              raise ClientRequestException("%d %s @ %s: %s" % (res.status_code, res.reason, url, res.content), res)
          elif res.status_code >= 300:
              raise RedirectionException("%d %s @ %s: %s" % (res.status_code, res.reason, url, res.content), res)
          return result
docs: Returns parsed JSON or raises an exception appropriately.