OfficialJev Repos & SDKs
Python SDK Exceptions
The Python SDK error hierarchy: HTTP status classes, rate-limit wait hints, connection and timeout errors, and response-body validation failures.
- Format
- Docs
- Published by
- TypeSafe AI
- Last verified
- Oct 2026
Works forJev for Classification
Used inJev for Software & DevTools
- Languages
- Python
Highlights
- TypeSafeAPIError carries status, body, headers, a credential-free endpoint, and x-typesafe-request-id.
- Status classes cover 400, 401, 403, 404, 422, 429, and 5xx. RateLimitError exposes retry_after_ms.
- TypeSafeAPIConnectionError is a failed request with no HTTP response. TypeSafeAPITimeoutError subclasses it.
- TypeSafeAPIResponseValidationError is a 2xx body that failed the response model, with a dotted field_path.
Watch out
A reference page. Retry behavior for 429 and 5xx lives on the RetryPolicy page.
Questions about this entry
Short answers drawn from the linked project or page.
TypeSafeAPIError carries status, body, headers, a credential-free endpoint, and the x-typesafe-request-id header. Status classes cover 400, 401, 403, 404, 422, 429, and 5xx.
TypeSafeAPITimeoutError subclasses TypeSafeAPIConnectionError for failed requests with no HTTP response, and TypeSafeAPIResponseValidationError covers a 2xx body that failed the response model, exposing a dotted field_path.
TypeSafeError, which subclasses Exception. Every SDK failure descends from it: HTTP failures through TypeSafeAPIError and connection problems through TypeSafeAPIConnectionError.
TypeSafeRateLimitError exposes retry_after_ms, parsed from the Retry-After headers, or None when the server did not send one. It is the class for a 429 response.
The request method and URL without credentials, query parameters, or fragment, when available. request_id reads the x-typesafe-request-id response header and is None if absent.
TypeSafeAPIResponseValidationError marks a 2xx body that was missing or structurally invalid required data, and exposes a dotted field_path like answers.tone.confidence pointing at the offending field.
For response validation errors the args tuple is status, body, headers, field_path, and endpoint. Timeout errors instead carry the timeout setting in seconds or as an httpx2.Timeout.
More Jev resources like this
RetryPolicy for the Python SDK: attempt count, exponential backoff with jitter, which HTTP statuses retry, and a total time budget.
Jev Repos & SDKsDocs#official#docs#sdk
Official
Release notes for the official Python SDK, from the 14 September 2026 public release through the Pydantic migration and the HTTP/2 extra.
Jev Repos & SDKsDocs#official#docs#sdk
Official
How the Python SDK types questions: Noul, Choice, and Score as objects or dictionaries, including optional JSON instructions and criteria.
Jev Repos & SDKsDocs#official#docs#sdk
Official
Default settings and environment variable names for the Python SDK, including the API root, model alias, and per-request timeout.
Jev Repos & SDKsDocs#official#docs#sdk
Official
TypeSafeClient, the synchronous Python client: ask questions, list models, and set the key, model, retry policy, and HTTP timeout.
Jev Repos & SDKsDocs#official#docs#sdk
Official
Shared Python SDK types: JSONValue, a nested JSON-like value that may be None, and descriptions built from strings or JSON values.
Jev Repos & SDKsDocs#official#docs#sdk
Official
From the Jev guides
Original write-ups on what this entry is for.
Every decision path has a failure posture, whether you chose one or not. How to put retries in the client, bound the whole call, and make the fallback an explicit, per-action policy.
Jev Practices & Patterns#reliability#retries#api
Read article
Closed weights have not stopped the ecosystem from rebuilding the shape in the open. API-compatible servers, retrained heads on small models, and inference-time tricks that skip generation entirely.
Jev Repos & SDKs#open-models#research#local
Read article
From the Jev community
Posts from builders shipping with Jev right now.