Trakt Errors¶
All Trakt related errors that are worth processing. Note that 412 response codes are ignored because the only requests that this library sends out are guaranteed to have the application/json MIME type set.
- exception trakt.errors.AccountLimitExceeded(response=None)¶
Bases:
RateLimitExceptionTraktException type to be raised when a 420 return code is received
- property account_limit¶
Get the account limit details from response headers.
- Returns:
str|None: The value of x-account-limit header or None if not present
- http_code = 420¶
- message = 'Account Limit Exceeded - list count, item count, etc'¶
- exception trakt.errors.BadRequestException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 400 return code is received
- http_code = 400¶
- message = "Bad Request - request couldn't be parsed"¶
- exception trakt.errors.BadResponseException(response=None, details=None)¶
Bases:
TraktExceptionTraktException type to be raised when json could not be decoded
- http_code = -1¶
- message = 'Bad Response - Response could not be parsed'¶
- exception trakt.errors.ConflictException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 409 return code is received
- http_code = 409¶
- message = 'Conflict - resource already created'¶
- exception trakt.errors.ForbiddenException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 403 return code is received
- http_code = 403¶
- message = 'Forbidden - invalid API key or unapproved app'¶
- exception trakt.errors.LockedUserAccountException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 423 return code is received
- http_code = 423¶
- message = 'Locked User Account - have the user contact support'¶
- exception trakt.errors.MethodNotAllowedException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 405 return code is received
- http_code = 405¶
- message = "Method Not Found - method doesn't exist"¶
- exception trakt.errors.NotFoundException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 404 return code is received
- http_code = 404¶
- message = 'Not Found - method exists, but no record found'¶
- exception trakt.errors.OAuthException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 401 return code is received
- http_code = 401¶
- message = 'Unauthorized - OAuth must be provided'¶
- exception trakt.errors.OAuthRefreshException(response=None)¶
Bases:
OAuthException- property error¶
- property error_description¶
- exception trakt.errors.ProcessException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 422 return code is received
- http_code = 422¶
- message = 'Unprocessable Entity - validation errors'¶
- exception trakt.errors.RateLimitException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 429 return code is received
- property details¶
- http_code = 429¶
- message = 'Rate Limit Exceeded'¶
- property retry_after¶
- exception trakt.errors.TraktBadGateway(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 502 error is raised
- http_code = 502¶
- message = 'Trakt Unavailable - Bad Gateway'¶
- exception trakt.errors.TraktException(response=None)¶
Bases:
ExceptionBase Exception type for trakt module
- http_code = None¶
- message = None¶
- exception trakt.errors.TraktInternalException(response=None)¶
Bases:
TraktExceptionTraktException type to be raised when a 500 error is raised
- property error_message¶
- http_code = 500¶
- message = 'Internal Server Error'¶
Bases:
TraktExceptionTraktException type to be raised when a 503 error is raised