Errors

All of the custom errors that are used within WarMAC.

Base Error

exception errors.WarMACBaseError

Bases: Exception

Base error raised in WarMAC.

Generic Errors

exception errors.CommandError

Bases: WarMACBaseError

Raised if the subparser field of argparse.Namespace does not exist in main.SUBCMD_DISPATCH.

exception errors.NoListingsFoundError

Bases: WarMACBaseError

Raised if no order listings are found given the set of parameters that the user gives the program.

HTTP Errors

exception errors.WarMACHTTPError

Bases: WarMACBaseError

Raised if the request made by the user returned an HTTP Status code that was not 200.

exception errors.UnauthorizedAccessError

Bases: WarMACHTTPError

Raised on HTTP status code 401, which indicates that authorization via proper user credentials is needed to access this resource.

exception errors.ForbiddenRequestError

Bases: WarMACHTTPError

Raised on HTTP status code 403, which indicates that access to the desired resource is forbidden.

exception errors.MalformedURLError

Bases: WarMACHTTPError

Raised on HTTP status code 404, which indicates that the resource in question does not exist.

exception errors.MethodNotAllowedError

Bases: WarMACHTTPError

Raised on HTTP status code 405, which indicates that the server knows the method, but the target resource doesn’t support it.

exception errors.InternalServerError

Bases: WarMACHTTPError

Raised on HTTP status code 500, which indicates that the server has encountered an internal error that prevents it from fulfilling the user’s request.

exception errors.RateLimitError

Bases: WarMACHTTPError

Raised on HTTP status code 429, which indicates that the an excessive number of requests per second have been made to the WFM server.

exception errors.UnknownError

Bases: WarMACHTTPError

Raised if the HTTP Response Code is not covered by any other error previously stated.