[BUG] Native Azure provider ignores timeout and max_retries on the completions path
维护者通常 1 天内回复
评估
调研方向
Find AzureCompletion._make_client_kwargs() and compare the default completions path with the responses path, which already forwards these settings. Check the sync and async client construction and related tests for retry and timeout configuration. Done when both completions clients receive the expected retry and timeout values; linked pull request #9881 indicates work is already underway.
由索引模型根据 Issue 内容生成。
描述
Description
LLM(model="azure/...", timeout=..., max_retries=...) accepts timeout and max_retries on AzureCompletion (and exports both in to_config_dict() and forwards them when api="responses"), but on the default api="completions" path _make_client_kwargs() never passes either setting to ChatCompletionsClient or AsyncChatCompletionsClient.
As a result:
max_retries(includingmax_retries=0to disable SDK retries or a higher count likemax_retries=5) is ignored, and both sync and async Azure clients always useazure-core's defaulttotal_retries=3(even differing fromAzureCompletion's ownmax_retries: int = 2field default).timeoutis ignored, leavingconnection_timeoutandread_timeoutat the 300s SDK defaults.
Minimal Reproduction
from crewai import LLM
llm = LLM(
model="azure/gpt-4o",
api_key="test-key",
endpoint="https://example.openai.azure.com",
timeout=15.0,
max_retries=0,
)
sync_client = llm._get_sync_client()
print("total_retries:", sync_client._config.retry_policy.total_retries) # 3 instead of 0
print("read_timeout:", sync_client._client._pipeline._transport.connection_config.read_timeout) # 300 instead of 15.0
Expected Behavior
_make_client_kwargs() passes retry_total=self.max_retries and, when self.timeout is not None, connection_timeout=self.timeout and read_timeout=self.timeout so both the sync and async Azure AI Inference clients honor the configured retry and timeout settings.
- 主要语言
- Python
- 星标
- 61.2k
- 派生
- 9.2k
- 平均合并
- 1 天 14 小时
- 30 天内合并 PR
- 180
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
crewAIInc/crewAI 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 1 天内回复
-
[FEATURE] Add Straitly as a native OpenAI-compatible LLM provider可能已有人在做 @HashimSyedUBC 于 2 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
[BUG] Native OpenAI sync streaming with response_model returns an empty string and emits no completed event when the parse is missing可能已有人在做 @basil-k-aji-dev 于 3 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 1 天内回复
-
[BUG] Native Azure provider ignores the seed setting可能已有人在做 @basil-k-aji-dev 于 3 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
crewAIInc/crewAI#9787 · 1 条评论 ·
维护者通常 1 天内回复
-
[BUG] LiteLLM path reports 0 cached and reasoning tokens in the usage summary可能已有人在做 @basil-k-aji-dev 于 3 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
相似的 Issue
-
bug harness
难度 2/5 1-3 小时 新手友好度 72/100
mruangutai/harness#2687 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 68/100
modal-labs/modal-client#4158 ·
-
good first issue
难度 1/5 1 小时以内 新手友好度 72/100
维护者通常 1 天内回复
-
难度 2/5 半天 新手友好度 72/100
The-Swarm-Corporation/swarms-rs#168 ·
维护者通常 1 天内回复
-
[BUG] SMTP listener now binds to EMAIL_PORT instead of 2525 since the gunicorn switch 5.0.3-ls373未关闭
难度 2/5 1-3 小时 新手友好度 72/100
linuxserver/docker-healthchecks#137 · 1 条评论 ·