From cd0a52de2e14d93d42744be5544a3a177bd46d75 Mon Sep 17 00:00:00 2001 From: "open-swe[bot]" Date: Wed, 6 Aug 2025 17:03:28 +0000 Subject: [PATCH] Apply patch [skip ci] --- .../tests/integration_tests/test_gpt_oss_tools.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/libs/partners/ollama/tests/integration_tests/test_gpt_oss_tools.py b/libs/partners/ollama/tests/integration_tests/test_gpt_oss_tools.py index d84a8c4e73c..e2a50165aab 100644 --- a/libs/partners/ollama/tests/integration_tests/test_gpt_oss_tools.py +++ b/libs/partners/ollama/tests/integration_tests/test_gpt_oss_tools.py @@ -191,11 +191,11 @@ class TestGptOssToolCallingIntegration: llm_with_tools = llm.bind_tools([get_weather]) # Stream a response - chunks = [] - for chunk in llm_with_tools.stream( - "What's the weather in Tokyo? Use the weather tool." - ): - chunks.append(chunk) + chunks = list( + llm_with_tools.stream( + "What's the weather in Tokyo? Use the weather tool." + ) + ) # Should have received chunks assert len(chunks) > 0 @@ -359,3 +359,4 @@ class TestGptOssErrorHandling: # Should have no tool calls assert not response.tool_calls or len(response.tool_calls) == 0 +