Skip to content

Commit 0bd6503

Browse files
Merge branch 'webb/openai/streaming-response' into webb/openai/add-response-model
2 parents 1cdc590 + edf0a4f commit 0bd6503

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

sentry_sdk/integrations/openai.py

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -467,7 +467,6 @@ def _common_set_output_data(
467467
response: "Any",
468468
input: "Any",
469469
integration: "OpenAIIntegration",
470-
start_time: "Optional[float]" = None,
471470
finish_span: bool = True,
472471
) -> None:
473472
if hasattr(response, "model"):
@@ -565,7 +564,7 @@ def _new_chat_completion_common(f: "Any", *args: "Any", **kwargs: "Any") -> "Any
565564
)
566565
else:
567566
_set_completions_api_output_data(
568-
span, response, kwargs, integration, start_time, finish_span=True
567+
span, response, kwargs, integration, finish_span=True
569568
)
570569

571570
return response
@@ -576,7 +575,6 @@ def _set_completions_api_output_data(
576575
response: "Any",
577576
kwargs: "dict[str, Any]",
578577
integration: "OpenAIIntegration",
579-
start_time: "Optional[float]" = None,
580578
finish_span: bool = True,
581579
) -> None:
582580
messages = kwargs.get("messages")
@@ -589,7 +587,6 @@ def _set_completions_api_output_data(
589587
response,
590588
messages,
591589
integration,
592-
start_time,
593590
finish_span,
594591
)
595592

@@ -711,7 +708,6 @@ def _set_responses_api_output_data(
711708
response: "Any",
712709
kwargs: "dict[str, Any]",
713710
integration: "OpenAIIntegration",
714-
start_time: "Optional[float]" = None,
715711
finish_span: bool = True,
716712
) -> None:
717713
input = kwargs.get("input")
@@ -724,7 +720,6 @@ def _set_responses_api_output_data(
724720
response,
725721
input,
726722
integration,
727-
start_time,
728723
finish_span,
729724
)
730725

@@ -855,7 +850,6 @@ def _set_embeddings_output_data(
855850
response: "Any",
856851
kwargs: "dict[str, Any]",
857852
integration: "OpenAIIntegration",
858-
start_time: "Optional[float]" = None,
859853
finish_span: bool = True,
860854
) -> None:
861855
input = kwargs.get("input")
@@ -868,7 +862,6 @@ def _set_embeddings_output_data(
868862
response,
869863
input,
870864
integration,
871-
start_time,
872865
finish_span,
873866
)
874867

@@ -1056,7 +1049,7 @@ def _new_responses_create_common(f: "Any", *args: "Any", **kwargs: "Any") -> "An
10561049
)
10571050
else:
10581051
_set_responses_api_output_data(
1059-
span, response, kwargs, integration, start_time, finish_span=True
1052+
span, response, kwargs, integration, finish_span=True
10601053
)
10611054

10621055
return response

0 commit comments

Comments
 (0)