Exceptions¶
Custom exception hierarchy for COMcheck API errors.
exceptions
¶
Custom exceptions for COMcheck API client.
COMCheckAPIError
¶
Bases: Exception
Base exception for COMcheck API errors.
COMCheckHTTPError
¶
Bases: COMCheckAPIError
HTTP request failed.
Initialize with the HTTP status code, message, and optional response body.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
status_code
|
int
|
The HTTP status code returned by the API. |
required |
message
|
str
|
Human-readable error description. |
required |
response_data
|
str
|
Raw response body text (empty string if unavailable). |
''
|
Source code in comcheck_api/exceptions.py
COMCheckValidationError
¶
Bases: COMCheckAPIError
Raised when request or response data fails Pydantic or schema validation.
COMCheckConnectionError
¶
Bases: COMCheckAPIError
Raised when the HTTP client cannot reach the COMcheck API server.
COMCheckSimulationError
¶
Bases: COMCheckAPIError
Raised when a simulation request fails or returns unexpected data.
COMCheckProjectNotFoundError
¶
Bases: COMCheckAPIError
Project not found.
Initialize with the ID of the project that was not found.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
project_id
|
str
|
The project ID that could not be located. |
required |