requests-全部異常歸類

IOError RequestException HTTPError(RequestException)  
UnrewindableBodyError(RequestException)  
RetryError(RequestException)  
ConnectionError(RequestException) ProxyError(ConnectionError)
SSLError(ConnectionError)
  ConnectTimeout(ConnectionError, Timeout)
Timeout(RequestException) ReadTimeout
URLRequired(RequestException)  
TooManyRedirects(RequestException)  
MissingSchema(RequestException, ValueError)  
InvalidSchema(RequestException,ValueError)  
InvalidURL(RequestException,ValueError)  
InvalidHeader(RequestException,ValueError)  
ChunkedEncodingError(RequestException)  
StreamConsumedError(RequestException,TypeError)  
ContentDecodingError(RequestException,BaseHTTPError)  
RequestsWarning(Warning)  FileModeWarning(RequestsWarning, DeprecationWarning)  

  異常官方文檔:http://www.python-requests.org/en/master/_modules/requests/exceptions/#RequestExceptionpython

相關文章
相關標籤/搜索