The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
fix transcription exception handling - /audio/transcriptions (#16791)
Otavio Brito6e5c7c0008f6
diff --git a/litellm/proxy/proxy_server.py b/litellm/proxy/proxy_server.pyindex 13307742860..7c415b8106e 100644--- a/litellm/proxy/proxy_server.py+++ b/litellm/proxy/proxy_server.py@@ -5483,6 +5483,7 @@ async def audio_transcriptions(file_object = io.BytesIO(file_content)file_object.name = file.filenamedata["file"] = file_object+try:### CALL HOOKS ### - modify incoming data / reject request before calling the modeldata = await proxy_logging_obj.pre_call_hook(@@ -5500,7 +5501,7 @@ async def audio_transcriptions()response = await llm_callexcept Exception as e:- raise HTTPException(status_code=500, detail=str(e))+ raise efinally:file_object.close() # close the file read in by io library