mirror of
https://github.com/chriswritescode-dev/opencode-manager.git
synced 2026-12-06 04:44:21 +01:00
refresh provider caches on config and stream refreshes
This commit is contained in:
1 parent
8cc524bc32
commit
94a35194df
1 file changed
+3
@@ -1193,6 +1193,7 @@ export function EventProvider({ children }: { children: React.ReactNode }) {
|
||||
break
|
||||
case 'config.updated':
|
||||
invalidateQueryKeysDebounced(queryClient, [['opencode', 'config'], ['opencode-config']])
|
||||
invalidateProviderCachesDebounced(queryClient)
|
||||
break
|
||||
case 'ssh.host-key-request':
|
||||
setSSHHostKeyRequest(event.properties)
|
||||
@@ -1233,6 +1234,7 @@ export function EventProvider({ children }: { children: React.ReactNode }) {
|
||||
void syncRunningShells(collectTrackedDirectories())
|
||||
invalidateChildSessionCaches(queryClient)
|
||||
invalidateQueryKeysDebounced(queryClient, LOCATION_CATALOG_QUERY_KEYS)
|
||||
invalidateProviderCachesDebounced(queryClient)
|
||||
startStatusPoll()
|
||||
} else {
|
||||
streamConnectedRef.current = false
|
||||
@@ -1259,6 +1261,7 @@ export function EventProvider({ children }: { children: React.ReactNode }) {
|
||||
void syncRunningShells(directories)
|
||||
invalidateChildSessionCaches(queryClient)
|
||||
invalidateQueryKeysDebounced(queryClient, LOCATION_CATALOG_QUERY_KEYS)
|
||||
invalidateProviderCachesDebounced(queryClient)
|
||||
}
|
||||
|
||||
const initialDirectories = [...new Set((reposRef.current ?? []).map(r => r.fullPath))]
|
||||
|
||||
Reference in new issue
Block a user