fix(multimodel): handle 302 redirect when downloading files

This commit is contained in:
Eternity
2026-03-13 16:46:03 +08:00
parent 85770dc037
commit 73aee97be5
2 changed files with 4 additions and 4 deletions

View File

@@ -75,7 +75,7 @@ class AudioTranscriptionService:
try:
# 下载音频文件
async with httpx.AsyncClient(timeout=60.0) as client:
audio_response = await client.get(audio_url)
audio_response = await client.get(audio_url, follow_redirects=True)
audio_response.raise_for_status()
audio_data = audio_response.content