code: def raise_for_not_ok_status(response):
      
      if response.code != OK:
          raise HTTPError('Non-200 response code (%s) for url: %s' % (
              response.code, uridecode(response.request.absoluteURI)))
  
      return response
docs: Raises a `requests.exceptions.HTTPError` if the response has a non-200
      status code.