Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@priyansh4320
Copy link
Collaborator

@priyansh4320 priyansh4320 commented Jul 15, 2025

Why are these changes needed?

  • This is a bug-fix Validation Error raised when stream=True is set.

Root Cause Analysis:

  • The OpenAILLMConfigEntry, AzureOpenAILLMConfigEntry, and DeepSeekLLMConfigEntry classes (in autogen/oai/client.py) originally did not define a 'stream' field, but the config you provided included it. Since the base LLMConfigEntry uses Pydantic with extra="forbid", any extra fields not explicitly declared in the model cause a validation error.

Solution:

  • Added stream:bool= False into OpenAILLMConfigEntry, AzureOpenAILLMConfigEntry, and DeepSeekLLMConfigEntry classes.

Related issue number

Closes #1912

Checks

@priyansh4320 priyansh4320 self-assigned this Jul 15, 2025
@priyansh4320 priyansh4320 added the bug Something isn't working label Jul 15, 2025
@priyansh4320 priyansh4320 force-pushed the 1912-bug-docs-validation-mismatch-stream-field-in-config_list-raises-validation-error branch 3 times, most recently from ede719f to 9723424 Compare July 15, 2025 18:38
…rs/priyanshu/Documents/GitHub/ag2/test/oai/test.pyeam=True'

fix: formatting and test

fix: formatting

fix: formatting

fix: groupchat test

fix: formatting
@priyansh4320 priyansh4320 force-pushed the 1912-bug-docs-validation-mismatch-stream-field-in-config_list-raises-validation-error branch from 9723424 to f214984 Compare July 15, 2025 18:44
@marklysze
Copy link
Collaborator

@priyansh4320 are you able to resolve the branch conflicts with client.py so this can be merged?

Copy link
Collaborator

@marklysze marklysze left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @priyansh4320!

@marklysze marklysze enabled auto-merge July 25, 2025 21:01
@marklysze marklysze disabled auto-merge July 25, 2025 21:05
@marklysze marklysze merged commit e92d0e8 into main Jul 25, 2025
16 checks passed
@marklysze marklysze deleted the 1912-bug-docs-validation-mismatch-stream-field-in-config_list-raises-validation-error branch July 25, 2025 21:05
@codecov
Copy link

codecov bot commented Jul 25, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.

❗ There is a different number of reports uploaded between BASE (f0d5684) and HEAD (6cdbeb2). Click for more details.

HEAD has 641 uploads less than BASE
Flag BASE (f0d5684) HEAD (6cdbeb2)
core-llm 8 0
3.9 37 0
ubuntu-latest 80 1
ollama 15 0
bedrock 15 0
cerebras 15 0
3.13 40 0
lmm 4 0
teachable 4 0
3.11 50 1
openai-realtime 1 0
gemini 15 0
gemini-realtime 1 0
macos-latest 58 0
anthropic 16 0
3.10 43 0
core-without-llm 14 1
3.12 36 0
gpt-assistant-agent 3 0
agent-eval 1 0
deepseek 1 0
retrievechat 8 0
retrievechat-qdrant 8 0
windows-latest 68 0
llama-index-agent 3 0
retrievechat-couchbase 3 0
retrievechat-mongodb 3 0
retrievechat-pgvector 3 0
long-context 3 0
captainagent 1 0
autobuild 1 0
together 14 0
groq 14 0
websurfer 15 0
mistral 14 0
cohere 15 0
swarm 14 0
Files with missing lines Coverage Δ
autogen/oai/client.py 55.53% <100.00%> (-7.85%) ⬇️

... and 65 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Docs / validation mismatch: stream field in config_list raises validation error

5 participants