From 1a03ed8b7691281a282e426bca91611f10a97b7b Mon Sep 17 00:00:00 2001 From: Harmon Date: Sun, 31 Oct 2021 14:06:49 -0500 Subject: [PATCH] Remove signatures from documentation of exceptions --- tweepy/errors.py | 40 +++++++++++++++++++++++++++------------- 1 file changed, 27 insertions(+), 13 deletions(-) diff --git a/tweepy/errors.py b/tweepy/errors.py index 6da5575..4336b30 100644 --- a/tweepy/errors.py +++ b/tweepy/errors.py @@ -20,7 +20,9 @@ class TweepyException(Exception): class HTTPException(TweepyException): - """Exception raised when an HTTP request fails + """HTTPException() + + Exception raised when an HTTP request fails Attributes ---------- @@ -67,40 +69,50 @@ class HTTPException(TweepyException): class BadRequest(HTTPException): - """Exception raised for a 400 HTTP status code - + """BadRequest() + + Exception raised for a 400 HTTP status code + .. versionadded:: 4.0 """ pass class Unauthorized(HTTPException): - """Exception raised for a 401 HTTP status code - + """Unauthorized() + + Exception raised for a 401 HTTP status code + .. versionadded:: 4.0 """ pass class Forbidden(HTTPException): - """Exception raised for a 403 HTTP status code - + """Forbidden() + + Exception raised for a 403 HTTP status code + .. versionadded:: 4.0 """ pass class NotFound(HTTPException): - """Exception raised for a 404 HTTP status code - + """NotFound() + + Exception raised for a 404 HTTP status code + .. versionadded:: 4.0 """ pass class TooManyRequests(HTTPException): - """Exception raised for a 429 HTTP status code - + """TooManyRequests() + + Exception raised for a 429 HTTP status code + .. versionchanged:: 4.0 Renamed from ``RateLimitError`` """ @@ -108,8 +120,10 @@ class TooManyRequests(HTTPException): class TwitterServerError(HTTPException): - """Exception raised for a 5xx HTTP status code - + """TwitterServerError() + + Exception raised for a 5xx HTTP status code + .. versionadded:: 4.0 """ pass -- 2.25.1