[codex] Dedupe fallback model metadata warnings#21090
Conversation
|
@codex review |
|
Codex Review: Didn't find any major issues. What shall we delve into next? ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d6a6e3f8f5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
fcoury-oai
left a comment
There was a problem hiding this comment.
Smoke tested the branch locally:
- Started the TUI with an unknown model slug and sent two turns in the same session. Confirmed the fallback metadata warning appeared only once for that model slug.
- Restarted with a hyphenated provider-prefixed known model (
openai-codex/gpt-5.4). Confirmed no fallback metadata warning was shown. - Restarted with a multi-segment namespace (
team/openai-codex/gpt-5.4). Confirmed the fallback metadata warning still appears, so the new matching stays limited to one provider-prefix segment.
One remark: this only dedupes repeated warnings on the TUI surface. Codex App may still show repeated warnings even thought I did not test that path. Calling it out in case you didn't think of it.
Code looks good, approved 👍
|
@fcoury-oai fair point, and yes I did consider this limitation. In the interest of keeping the changes isolated to the TUI I accepted this, if we see any reports of this happening in the App we should consider core changes versus deduping in that client. |
Fixes #21070.
This is a small cleanup around model metadata handling for gateway/provider model names. It follows the report and proposed direction from @dkbush by keeping the fallback metadata warning useful without repeating it every turn, and by tightening the existing provider-prefix lookup path.
Testing:
just fmt.git diff --check.