Repository navigation
Conversation
Fixes anomalyco#60851 Co-Authored-By: Claude Opus 5.5 <[email protected]>
There was a problem hiding this comment.
The change looks correct: useConnected() now reads integrations for the TUI's current location, the same way the provider and model lists in the /model dialog already do. Every caller renders inside LocationProvider. When the ref isn't set yet, list(undefined) still falls back to the default location, so startup behaves as before.
I couldn't reproduce the bug. I drove the TUI with the simulated provider and a connected Exa integration on the base, opened /model and searched simulation. Both from the home screen and after /cd sub, the base already showed the provider header and matched the search. The bug seems to need the default location's integration list to be missing or stale while the TUI is somewhere else. Could you share the exact steps that lead there (for example, opening a session from another directory, a workspace, or attaching to a remote server)? Before/after screenshots of /model would also help. The connected-provider, plugin-model and app-lifecycle tests pass. Running tsc directly shows no new errors; the typecheck script itself couldn't run in my environment.
Public API: unchanged.
Note: the open PR #60591 makes the same one-line change in use-connected.tsx as part of a broader fix, so the two will conflict on this file.
Related: #60587
GiuseppeBellamacina
left a comment
There was a problem hiding this comment.
useConnected() now passes useLocation().ref to integration.list(), so it reads the TUI's current location instead of the default one, which matches the description. The change is minimal. I saw a mention that #60591 changes the same line, so whichever lands second will need a rebase.
Issue for this PR
Closes #60851
Type of change
What does this PR do?
useConnected()readdata.location.integration.list()without a location ref, so it looked at the default location instead of the TUI's current one and got[]. Withconnected()false, the/modelpicker sets nocategoryon its options, so typing a provider name matched nothing. The hook now passesuseLocation().ref, like the provider and model lists in the same dialog. Every caller ofuseConnected()already runs insideLocationProvider.How did you verify your code works?
/modellists all of that provider's models again. Without the change it lists none.bun run typecheckinpackages/tui: no type errors.bun testinpackages/tui: one failure ("the art stops every frame when hidden..."), and it fails the same way ondevwithout this change.Checklist
🤖 Generated with Claude Code
Added by the opencode bot (AI-generated).
Related: #60587