mirror of
https://github.com/chriswritescode-dev/opencode-manager.git
synced 2026-12-06 21:04:23 +01:00
fix(models): reload the model catalog on reconnect and broadcast its events
Model pickers without a location, such as the goal auditor and walkthrough model settings, could stay stuck on an empty model list. OpenCode's model and provider catalog events were only delivered to clients subscribed to the originating directory, and the provider catalog was not reloaded on a browser stream reconnect or upstream resync, so a list cached empty while OpenCode was loading or restarting never refreshed. Route model.updated, provider.updated and integration.updated through the resolved-event broadcast like the command, agent and skill catalogs, and reload the provider catalog on reconnect and resync alongside them.
This commit is contained in:
1 parent
4eec94b74c
commit
9c32ba2038
4 files changed
+5
-2
No files matched your search
@@ -805,7 +805,7 @@ describe('SSEAggregator location-scoped catalog event broadcast', () => {
|
||||
sseAggregator.setScheduledSessionsResolver(() => [])
|
||||
})
|
||||
|
||||
it.each(['command.updated', 'agent.updated', 'skill.updated'])(
|
||||
it.each(['command.updated', 'agent.updated', 'skill.updated', 'model.updated', 'provider.updated', 'integration.updated'])(
|
||||
'broadcasts a location-scoped %s catalog event to every client without leaking other location-scoped events',
|
||||
(type) => {
|
||||
const subscribed = createCapturingClient()
|
||||
|
||||
Reference in new issue
Block a user