修复provider刷不出来的问题 - #13
Conversation
Royalvice
left a comment
There was a problem hiding this comment.
Blocking: the App hook must not turn every observed loading snapshot into refreshProvidersSnapshot({}). Settings mounts both ProvidersSection and nested ProviderCatalogList, each with an independent useProvidersSnapshot instance and local refresh guard. On a cold snapshot they can both force a full refresh.
The global refresh path calls clearCachedProviders(undefined), resets all snapshot scopes/in-flight loads, and starts force probes for every provider. That can discard earlier in-flight results, reset unrelated Workspace model snapshots to loading, and turn a user-requested provider-specific refresh into a global one.
Please move first-read catalog warm-up/recovery to the daemon ProviderSnapshotManager / ProviderCatalogSession, using the existing non-force, scope/provider-deduplicated warm-up path. The App should render the daemon snapshot and invoke force refresh only for an explicit user action. Please also add coverage for two same-scope consumers, an in-flight provider-specific refresh, scope isolation, and refresh failure/reconnect.
Summary
Motivation
Changes
How Tested