Skip to content

fix: prevent model reload from interrupting ACP startup#1178

Merged
su8su merged 1 commit into
mainfrom
fix_acp_start
Jul 17, 2026
Merged

fix: prevent model reload from interrupting ACP startup#1178
su8su merged 1 commit into
mainfrom
fix_acp_start

Conversation

@su8su

@su8su su8su commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a3297eb5e1

ℹ️ About Codex in GitHub

Codex has been enabled to automatically 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 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".


useEffect(() => {
if (!currentAgent || switchingModelRef || optimisticModelRef) return;
if (!providerSnapshotReady || providerError || !currentAgent || switchingModelRef || optimisticModelRef) return;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P2 Badge Gate model cleanup while providers are refreshing

When an initial provider snapshot fails and a later snapshot is retried, refreshProviderSnapshot clears error before awaiting the new fetch (src/stores/providers.ts:82-84) while leaving the old accounts/statuses in place. Since providerSnapshotReady stays true and this guard only checks providerError, the effect can run during that in-flight retry with empty/stale modelOptions and call updateAgentModel(..., null) before the providers settle, reintroducing the premature override clearing this patch is intended to avoid.

Useful? React with 👍 / 👎.

@su8su
su8su merged commit ff61f5d into main Jul 17, 2026
6 checks passed
@su8su
su8su deleted the fix_acp_start branch July 17, 2026 07:16
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