Skip to content

Open-source Python library for AI browser agents, plus Browser Use Cloud: stealth browsers and a hosted agent API.

reduce httpx.Limit

Magnus Müller2954924a4936
diff --git a/browser_use/llm/azure/chat.py b/browser_use/llm/azure/chat.py
index ce1af2c20..0a20e3552 100644
--- a/browser_use/llm/azure/chat.py
+++ b/browser_use/llm/azure/chat.py
@@ -83,7 +83,7 @@ class ChatAzureOpenAI(ChatOpenAILike):
else:
# Create a new async HTTP client with custom limits
_client_params['http_client'] = httpx.AsyncClient(
- limits=httpx.Limits(max_connections=1000, max_keepalive_connections=100)
+ limits=httpx.Limits(max_connections=20, max_keepalive_connections=6)
)
self.client = AsyncAzureOpenAIClient(**_client_params)