fix: enable proxy support in aiohttp by adding trust_env=True (#289)

This commit is contained in:
Xintao Wang 2025-06-07 15:30:13 +08:00 committed by GitHub
parent b5ec61bb9d
commit cda3870add
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -70,7 +70,7 @@ class EnhancedTavilySearchAPIWrapper(OriginalTavilySearchAPIWrapper):
"include_images": include_images,
"include_image_descriptions": include_image_descriptions,
}
async with aiohttp.ClientSession() as session:
async with aiohttp.ClientSession(trust_env=True) as session:
async with session.post(f"{TAVILY_API_URL}/search", json=params) as res:
if res.status == 200:
data = await res.text()