From fa3501d4485dc6711f9f049d1624722d3336dcec Mon Sep 17 00:00:00 2001 From: Chris Bartholomew Date: Mon, 9 Mar 2026 06:22:44 -0400 Subject: [PATCH] Fix Iris parser httpx read timeout for file uploads (#524) The httpx.AsyncClient was created without a timeout parameter, defaulting to 5 seconds for reads. This is too short for uploading PDFs to presigned URLs and waiting for Iris API responses. Set explicit timeouts: 30s default, 120s for reads. --- hindsight-api/hindsight_api/engine/parsers/iris.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hindsight-api/hindsight_api/engine/parsers/iris.py b/hindsight-api/hindsight_api/engine/parsers/iris.py index 7314b9fa..b049158d 100644 --- a/hindsight-api/hindsight_api/engine/parsers/iris.py +++ b/hindsight-api/hindsight_api/engine/parsers/iris.py @@ -62,7 +62,7 @@ class IrisParser(FileParser): """ content_type = mimetypes.guess_type(filename)[0] or "application/octet-stream" - async with httpx.AsyncClient() as client: + async with httpx.AsyncClient(timeout=httpx.Timeout(30.0, read=120.0)) as client: # Step 1: Request a presigned upload URL init_resp = await client.post( f"{_IRIS_BASE_URL}/org/{self._org_id}/files",