fix: models not shown in "Choose Model" modal after OAuth configuration completes#7891
Merged
Merged
Conversation
Signed-off-by: sheikhlimon <sheikhlimon404@gmail.com>
DOsinga
approved these changes
Mar 20, 2026
Collaborator
DOsinga
left a comment
There was a problem hiding this comment.
Clean fix for a real race condition — awaiting refreshProviders() before opening the modal is exactly right. Approved.
hydrosquall
pushed a commit
to hydrosquall/goose
that referenced
this pull request
Mar 31, 2026
…on completes (aaif-goose#7891) Signed-off-by: sheikhlimon <sheikhlimon404@gmail.com> Signed-off-by: Cameron Yick <cameron.yick@datadoghq.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
After completing OAuth configuration for ChatGPT Codex, the "Choose Model" modal opened automatically but didn't show ChatGPT Codex models. The provider list hadn't been refreshed yet, so the newly configured provider wasn't included.
Root Cause
In
ProviderGrid.tsx, theonProviderConfiguredcallback calledrefreshProviders()but didn't await it before opening the model selector modal. The provider list fetch was still in progress when the modal rendered.Fix
Make
onProviderConfigured asyncandawait refreshProviders()before setting the model provider state and opening the modal.Testing
Type of Change
AI Assistance
Screenshots/Demos (for UX changes)
Before:

After:
