From: Harmon Date: Sun, 31 Oct 2021 18:55:26 +0000 (-0500) Subject: Document HTTPException attributes X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=c62c31a0f3574e04b6e2f5996b90b5c1b5917485;p=tweepy.git Document HTTPException attributes --- diff --git a/tweepy/errors.py b/tweepy/errors.py index 3312ec5..6da5575 100644 --- a/tweepy/errors.py +++ b/tweepy/errors.py @@ -20,7 +20,19 @@ class TweepyException(Exception): class HTTPException(TweepyException): - """Exception raised when an HTTP request fails""" + """Exception raised when an HTTP request fails + + Attributes + ---------- + response : requests.Response + Requests Response from the Twitter API + api_errors : List[dict[str, Union[int, str]]] + The errors the Twitter API responded with, if any + api_codes : List[int] + The error codes the Twitter API responded with, if any + api_messages : List[str] + The error messages the Twitter API responded with, if any + """ def __init__(self, response): self.response = response