Skip to content

fix: set a default LiteLLM request timeout - #1886

Open
fcsguyxcw wants to merge 1 commit into
agent0ai:mainfrom
fcsguyxcw:codex/fix-default-litellm-timeout
Open

fcsguyxcw wants to merge 1 commit into
agent0ai:mainfrom
fcsguyxcw:codex/fix-default-litellm-timeout

Conversation

@fcsguyxcw

Copy link
Copy Markdown

Summary

  • set a 180-second default timeout for all direct LiteLLM calls
  • preserve existing global and per-model overrides
  • verify the default is merged and reaches streaming chat completion requests

Why

Without a timeout, an accepted request that stops producing data can await indefinitely, so Agent Zero never reaches its exception-driven retry path. The pinned LiteLLM direct completion API accepts timeout for both streaming and non-streaming calls. stream_timeout is primarily handled by LiteLLM Router, which Agent Zero does not use for these requests.

Tests

  • python -m pytest tests/test_stream_tool_early_stop.py (55 passed)
  • focused post-assertion run for the default merge and streaming propagation tests (2 passed)
  • git diff --check

Closes #1882

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: Streaming LLM calls hang indefinitely — no stream_timeout default, retry logic never triggers on stalled streams

1 participant