Skip to content

fix: always return ModelSettings from _build_model_settings#169

Open
jsonbailey wants to merge 1 commit intomainfrom
jb/fix-openai-model-settings
Open

fix: always return ModelSettings from _build_model_settings#169
jsonbailey wants to merge 1 commit intomainfrom
jb/fix-openai-model-settings

Conversation

@jsonbailey
Copy link
Copy Markdown
Contributor

@jsonbailey jsonbailey commented May 6, 2026

Summary

  • Remove the if kwargs else None guard in OpenAIAgentRunner._build_model_settings() so an empty ModelSettings() is returned instead of None when no parameters are set.

Test plan

  • Verify OpenAIAgentRunner works correctly when no model parameters are configured

🤖 Generated with Claude Code


Note

Low Risk
Low risk, localized behavior change that removes a None return path; only potential impact is if downstream code relied on model_settings=None semantics in the Agents SDK.

Overview
Ensures OpenAIAgentRunner._build_model_settings() always constructs and returns ModelSettings(**kwargs) instead of returning None when no known model parameters are set, so the agent is consistently initialized with a ModelSettings object.

Reviewed by Cursor Bugbot for commit 0138d69. Bugbot is set up for automated code reviews on this repo. Configure here.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@jsonbailey jsonbailey marked this pull request as ready for review May 6, 2026 00:49
@jsonbailey jsonbailey requested a review from a team as a code owner May 6, 2026 00:49
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.

1 participant