fix: stream internal model calls with idle timeouts (#5730)
* fix: stream internal model calls with idle timeouts * fix(providers): reject streams without terminal events
This commit is contained in:
1 parent
aeb7b207d7
commit
73410e0217
60 files changed
+815
-795
No files matched your search
@@ -110,7 +110,7 @@ async def test_loop_binds_request_context_for_tool_execution(tmp_path: Path) ->
|
||||
provider = MagicMock()
|
||||
calls = {"n": 0}
|
||||
|
||||
async def chat_with_retry(**_kwargs):
|
||||
async def chat_stream_with_retry(**_kwargs):
|
||||
calls["n"] += 1
|
||||
if calls["n"] == 1:
|
||||
return LLMResponse(
|
||||
@@ -119,7 +119,7 @@ async def test_loop_binds_request_context_for_tool_execution(tmp_path: Path) ->
|
||||
)
|
||||
return LLMResponse(content="done", tool_calls=[])
|
||||
|
||||
provider.chat_with_retry = chat_with_retry
|
||||
provider.chat_stream_with_retry = chat_stream_with_retry
|
||||
provider.get_default_model.return_value = "test-model"
|
||||
|
||||
loop = AgentLoop(
|
||||
|
||||
Reference in new issue
Block a user