From 0d5c76ea987c93190c8278f07d802a9e637af8d0 Mon Sep 17 00:00:00 2001 From: Benjamin Admin Date: Thu, 21 May 2026 11:52:59 +0200 Subject: [PATCH] =?UTF-8?q?fix(audit):=20P90-B1=20=E2=80=94=20DSI-Discover?= =?UTF-8?q?y=20Timeout=20120s=20->=20240s=20fuer=20BMW-Impressum?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit BMW-fafcb090 zeigte exception 'ReadTimeout' beim consent-tester-Call fuer anbieterkennzeichnung.html. Der Discovery-Lauf folgt 3 Sub-Documents (Versicherungsvermittler, Aufsicht, Berufsrecht) plus ePaaS-Captures — braucht regelmaessig >120s. Co-Authored-By: Claude Opus 4.7 (1M context) --- .../compliance/api/agent_compliance_check_routes.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/backend-compliance/compliance/api/agent_compliance_check_routes.py b/backend-compliance/compliance/api/agent_compliance_check_routes.py index 7d968edb..89ea7c19 100644 --- a/backend-compliance/compliance/api/agent_compliance_check_routes.py +++ b/backend-compliance/compliance/api/agent_compliance_check_routes.py @@ -1217,11 +1217,14 @@ async def _fetch_text(url: str, doc_type: str = "") -> tuple[str, list[dict]]: short_extract_types = {"cookie", "dse", "datenschutz", "privacy", "social_media"} max_docs = 1 if (doc_type or "") in short_extract_types else 3 try: - async with httpx.AsyncClient(timeout=120.0) as client: + # P90: 120s reicht nicht fuer BMW-Impressum (Auto-Discovery folgt + # 3 Sub-Docs). 240s gibt Spielraum. Mercedes faellt aktuell mit + # 120s auch oft an Akamai-Latenz. + async with httpx.AsyncClient(timeout=240.0) as client: resp = await client.post( f"{CONSENT_TESTER_URL}/dsi-discovery", json={"url": url, "max_documents": max_docs}, - timeout=120.0, + timeout=240.0, ) if resp.status_code == 200: payload = resp.json()