From 16842f0fdd4f2e921396ddc7d0b14ae834c189ce Mon Sep 17 00:00:00 2001 From: tin-berri Date: Mon, 22 Jun 2026 11:00:50 -0700 Subject: [PATCH] test(interactions): drop role from Interaction output fields to match Google spec (#30986) Google moved the role field off the top-level Interaction response schema onto the per-turn Turn schema, so the OpenAPI compliance canary test_interaction_response_fields started failing on main with "Output field 'role' not in spec". role on Turn is already asserted by test_turn_schema, so dropping it from the Interaction output_fields list realigns the test with the live spec without losing coverage. --- tests/test_litellm/interactions/test_openapi_compliance.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/test_litellm/interactions/test_openapi_compliance.py b/tests/test_litellm/interactions/test_openapi_compliance.py index aededaaca77..44c0b6e5b02 100644 --- a/tests/test_litellm/interactions/test_openapi_compliance.py +++ b/tests/test_litellm/interactions/test_openapi_compliance.py @@ -156,7 +156,10 @@ class TestResponseCompliance: # The response is the dedicated `Interaction` schema. Google moved the # output-only fields (notably the `steps` array, formerly `outputs`) # off `CreateModelInteractionParams` and onto `Interaction`; the request - # schema no longer carries `steps`. Keep this aligned with the live spec. + # schema no longer carries `steps`. Google later moved `role` off + # `Interaction` onto the per-turn `Turn` schema (asserted in + # test_turn_schema), so it is no longer a top-level output field here. + # Keep this aligned with the live spec. schema = spec_dict["components"]["schemas"]["Interaction"] # Output fields (readOnly). @@ -165,7 +168,6 @@ class TestResponseCompliance: "status", "created", "updated", - "role", "steps", "usage", ]