Skip to content

v0.47.0

Latest

Choose a tag to compare

@CyMule CyMule released this 05 Nov 18:06
acb2bce

What's Changed

Features

  • Expose the verdict the API declares on an error as typed attributes on every HTTP error: retryable, error_type, error_reason and audience. Errors the API raises deliberately publish these fields next to detail, eg a 503 OCR timeout with "retryable": false. Callers no longer need to parse err.body to read them. Each attribute is None when the body is not JSON, the field is absent, or its value has the wrong type. The retry loop reads retryable with the same parser.
  • Add skip_preflight to CreateWorkflow and UpdateWorkflow. Set it to True to skip the job preflight check for a workflow's jobs; on update, leaving it unset keeps the current value. WorkflowInformation.skip_preflight reports the workflow's current setting. For a one-off job, set "skip_preflight": true in the request_data JSON passed to jobs.create_job.

Fixes

  • Deserialize jobs the preflight check rejected. JobStatus and JobProcessingStatus gain REJECTED; previously jobs.get_job raised on a rejected job, and one rejected job failed the whole jobs.list_jobs page. JobInformation.status and JobDetails.processing_status now also accept a status this SDK version does not know, returning it as a plain str instead of raising. Known statuses are still returned as enum members, but the fields are typed Union[JobStatus, str] and Union[JobProcessingStatus, str], so type-checked code that reads .value or .name from them needs to handle the str case.
  • Expose why a job was rejected. JobNodeDetails gains failure_category (a PreflightFailureCategory, or a plain str for a category this SDK version does not know) and failure_reason, set on the node that failed preflight in jobs.get_job_details. Previously both were dropped during deserialization.
  • Bump locked certifi to 2026.10.19, which removes the emSign ECC Root CA - G3 root after eight eMudhra intermediate CA private keys were compromised. requests and httpx trust certifi's bundle and do not check revocation, so with the older bundle they accepted certificates chaining to that root. certifi is now also a direct dependency at >=2026.10.19, so pip installs pick up the new bundle too.
  • Long partitions behind a NAT or load balancer idle timeout could never return, leaving the client waiting for its full read timeout. SDK-owned HTTP clients now enable TCP keepalive, including split-PDF requests. Connections made through an HTTP(S)/SOCKS proxy are not covered. Configure probes with UNSTRUCTURED_CLIENT_TCP_KEEPALIVE_IDLE (60 seconds), UNSTRUCTURED_CLIENT_TCP_KEEPALIVE_INTERVAL (30 seconds), and UNSTRUCTURED_CLIENT_TCP_KEEPALIVE_COUNT (5); set UNSTRUCTURED_CLIENT_TCP_KEEPALIVE=0 or false to disable. Caller-supplied clients are unchanged.

Full Changelog: v0.46.4...v0.47.0