qbraid_core.HttpStatusMixin
- class qbraid_core.HttpStatusMixin
Adds
status_codeto exceptions that can carry an HTTP response.Mixed into the errors that service clients raise from an
except RequestsApiErrorhandler, and only those. Errors with no API request behind them — configuration, installation, validation — do not get the attribute, so its absence is meaningful rather than a permanentNone.Clients wrap transport failures with
raise ... from errand pass only a message, and__cause__is set after__init__returns, so the status cannot be captured at construction. It is read from the chain on access instead, which is why no raise site needs to thread it through.- __init__()
Methods
__init__()Attributes
status_codeHTTP status of the underlying failed request.