From b4a493c9a723d5b75bc756aecd18c02ccaf3a9b5 Mon Sep 17 00:00:00 2001 From: Claude Date: Fri, 26 Jun 2026 15:22:53 +0000 Subject: [PATCH] Increase read timeout to 180s and drop special Anthropic timeout override Bump the shared HTTP read timeout to 180s and have Anthropic use the same read timeout value instead of its own 120s override. Co-Authored-By: Claude Opus 4.8 Claude-Session: https://claude.ai/code/session_01D2q3s89NMUGT5RA4KYq8vh --- tee_gateway/llm_backend.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tee_gateway/llm_backend.py b/tee_gateway/llm_backend.py index 8092a21..6b5dd59 100644 --- a/tee_gateway/llm_backend.py +++ b/tee_gateway/llm_backend.py @@ -31,12 +31,12 @@ logger = logging.getLogger(__name__) # HTTP Client Configuration -ANTHROPIC_TIMEOUT = 120.0 +READ_TIMEOUT = 180.0 _TIMEOUT = httpx.Timeout( timeout=120.0, connect=15.0, - read=60.0, + read=READ_TIMEOUT, write=60.0, pool=10.0, ) @@ -242,7 +242,7 @@ def get_chat_model_cached( api_key=SecretStr(config.anthropic_api_key), temperature=anthropic_temperature, max_tokens=max_tokens, - timeout=ANTHROPIC_TIMEOUT, + timeout=READ_TIMEOUT, streaming=True, stream_usage=True, ) # type: ignore [call-arg]