exception documentation

A basic HTTP error.

Parameters
messageA short error message, for example "NOT FOUND".
Method __init__ Initializes a basic exception.
Method __str__ Undocumented
Instance Variable message Undocumented
Instance Variable response A complete HTML document for an error page.
Instance Variable status Refers to an HTTP status code, for example http.NOT_FOUND.
def __init__(self, code: Union[int, bytes], message: Optional[bytes] = None, response: Optional[bytes] = None): (source)

Initializes a basic exception.

Parameters
code:bytes or intRefers to an HTTP status code (for example, 200) either as an integer or a bytestring representing such. If no message is given, code is mapped to a descriptive bytestring that is used instead.
message:bytesA short error message, for example b"NOT FOUND".
response:bytesA complete HTML document for an error page.
def __str__(self) -> str: (source)

Undocumented

A complete HTML document for an error page.

Refers to an HTTP status code, for example http.NOT_FOUND.