Exceptions¶
Exception hierarchy for handling errors.
Base Exceptions¶
gdpy.exceptions.base.GDError ¶
gdpy.exceptions.base.RequestError ¶
Bases: GDError
Base exception for request-related errors.
This is the parent class for errors that occur during API requests, including authentication errors, rate limiting, and not found errors.
Authentication Errors¶
gdpy.exceptions.auth.AuthError ¶
Bases: RequestError
Base exception for authentication errors.
Raised when authentication-related operations fail.
gdpy.exceptions.auth.InvalidCredentialsError ¶
Bases: AuthError
Raised when login credentials are incorrect.
This exception is raised when attempting to login with an invalid username or password combination.
Attributes:
| Name | Type | Description |
|---|---|---|
error_code | The API error code (-11). |
gdpy.exceptions.auth.AccountDisabledError ¶
Bases: AuthError
Raised when the account has been disabled.
This exception is raised when attempting to login to an account that has been banned or disabled by moderators.
Attributes:
| Name | Type | Description |
|---|---|---|
error_code | The API error code (-12). |
Request Errors¶
gdpy.exceptions.invalid_request.InvalidRequestError ¶
Bases: RequestError
gdpy.exceptions.not_found.NotFoundError ¶
Bases: RequestError
Registration Errors¶
gdpy.exceptions.registration.UsernameTakenError ¶
Bases: RegistrationError
gdpy.exceptions.registration.EmailTakenError ¶
Bases: RegistrationError
gdpy.exceptions.registration.PasswordTooShortError ¶
Bases: RegistrationError
gdpy.exceptions.registration.UsernameTooShortError ¶
Bases: RegistrationError