You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 695bbf6
Browse filesBrowse the repository at this point in the historyBrowse files
fix: Altimate Base fallback ordering and retry latch
Three Codex review findings on the Altimate Base default-no-consent branch:
- `fallbackModel()`'s implicit last-resort pick in `local.tsx` used a naive
array-order `.find()` instead of mirroring `Provider.defaultModel()`'s
ordering, so keyless public Zen could be picked over a registered Base, and
Base could beat a provider the user actually connected depending on array
position. Extracted `pickImplicitFallbackProvider()` as a pure, directly
testable function that mirrors the server's ordering exactly, and added 3
unit tests covering: Base outranking Zen, a credentialed provider
outranking Base, and unchanged behavior when Base isn't registered.
- `dialog-provider.tsx` and `dialog-model.tsx` set the Altimate Base row's
one-shot activation latch before the async `selectAltimateBase()` resolved,
and never reset it on failure, permanently bricking the row for the rest of
the dialog session after a single failed attempt. Reset the latch when
`selectAltimateBase()` returns `false`, and added a full-render retry test
confirming a failed selection can be retried and re-fires registration.
- `altimate-onboarding.tsx`'s `chooseAltimateBase()` had the same bug, but on
the first-run welcome picker: it returned `true` synchronously right after
firing the unawaited `selectAltimateBase()` call, so `activateRow()` claimed
its one-shot latch before the registration attempt was known to have
failed. A failed Base registration then bricked Enter, `/` and mouse-up for
the rest of the dialog session on the picker shown to users with no model
at all. Reset the latch on failure the same way, keeping the double-input
guard intact for the in-flight window, and added a retry test to
`dialog-model-welcome.test.tsx` confirming the same row can be retried.
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
0 commit comments