RequestException
Extends IOError.
Base exception for all requests-related errors.
Constructor
RequestException(message: str, response: FastlyResponse | None = None, request: http_req.Request | None = None) -> NoneInitialize RequestException.
Parameters
- message: str
Error message
- response: FastlyResponse | Noneoptional =
None Optional response object that caused the error
- request: http_req.Request | Noneoptional =
None Optional request object that caused the error
Returns
None
Properties
Methods
Create a requests exception from an ErrorWithDetail.
Parameters
- err: ErrorWithDetail
The error to map from
- operation: str
Description of what operation failed
Returns
RequestException
Appropriate RequestException subclass instance
Create a requests exception from a FastlyError or subclass.
Parameters
- err: FastlyError
The error to map from
- operation: str
Description of what operation failed
Returns
RequestException
Appropriate RequestException subclass instance