Skip to content

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]

fix: remove duplicate gen_ai.response.finish_reasons block

Aneesh-Fiddler992861878838
diff --git a/litellm/integrations/opentelemetry.py b/litellm/integrations/opentelemetry.py
index 90e647d86bf..d116fc44658 100644
--- a/litellm/integrations/opentelemetry.py
+++ b/litellm/integrations/opentelemetry.py
@@ -1824,15 +1824,6 @@ class OpenTelemetry(CustomLogger):
value=safe_dumps([status]),
)
- # Extract finish reason from ResponsesAPIResponse.status
- status = response_obj.get("status")
- if status:
- self.safe_set_attribute(
- span=span,
- key=SpanAttributes.GEN_AI_RESPONSE_FINISH_REASONS.value,
- value=safe_dumps([status]),
- )
-
except Exception as e:
self.handle_callback_failure(
callback_name=self.callback_name or "opentelemetry"