Fix batch tests

This commit is contained in:
Sameer Kankute 2026-01-22 19:22:29 +05:30
parent 1657af81eb
commit 991fee056f
3 changed files with 7 additions and 7 deletions

View file

@ -396,7 +396,7 @@ class AnthropicPassthroughLoggingHandler:
# Add batch-specific metadata to indicate this is a pending batch job
litellm_model_response.choices = [Choices(
finish_reason="batch_pending",
finish_reason="stop",
index=0,
message={
"role": "assistant",
@ -438,7 +438,7 @@ class AnthropicPassthroughLoggingHandler:
# Add error-specific metadata
litellm_model_response.choices = [Choices(
finish_reason="batch_error",
finish_reason="stop",
index=0,
message={
"role": "assistant",
@ -472,7 +472,7 @@ class AnthropicPassthroughLoggingHandler:
# Add error-specific metadata
litellm_model_response.choices = [Choices(
finish_reason="batch_error",
finish_reason="stop",
index=0,
message={
"role": "assistant",

View file

@ -619,7 +619,7 @@ class VertexPassthroughLoggingHandler:
# Add batch-specific metadata to indicate this is a pending batch job
litellm_model_response.choices = [Choices(
finish_reason="batch_pending",
finish_reason="stop",
index=0,
message={
"role": "assistant",
@ -661,7 +661,7 @@ class VertexPassthroughLoggingHandler:
# Add error-specific metadata
litellm_model_response.choices = [Choices(
finish_reason="batch_error",
finish_reason="stop",
index=0,
message={
"role": "assistant",
@ -695,7 +695,7 @@ class VertexPassthroughLoggingHandler:
# Add error-specific metadata
litellm_model_response.choices = [Choices(
finish_reason="batch_error",
finish_reason="stop",
index=0,
message={
"role": "assistant",

View file

@ -127,7 +127,7 @@ class TestVertexAIBatchPassthroughHandler:
assert result is not None
assert "result" in result
assert "kwargs" in result
assert result["result"].choices[0].finish_reason == "batch_error"
assert result["result"].choices[0].finish_reason == "stop"
assert result["kwargs"]["batch_job_state"] == "JOB_STATE_FAILED"
def test_get_actual_model_id_from_router_with_router(self):