@@ -448,7 +448,7 @@ function workspaceSnapshotOrCatalog(
448448
449449// On-demand catalog clients read full entries from the cwd snapshot they fetch. Names still
450450// change the config when the machine catalog does, so the client refetches, and skill names
451- // keep skill links working where no snapshot is fetched.
451+ // and labels keep skill links working where no snapshot is fetched.
452452function withoutWorkspaceSnapshots (
453453 providers : ReadonlyArray < ServerProvider > ,
454454 catalogsPerCwd : ReadonlySet < string > = new Set ( ) ,
@@ -459,7 +459,7 @@ function withoutWorkspaceSnapshots(
459459 ...provider ,
460460 slashCommands : provider . slashCommands . map ( ( { name } ) => ( { name } ) ) ,
461461 skills : provider . skills . map (
462- ( { description : _d , shortDescription : _s , displayName : _n , ...skill } ) => skill ,
462+ ( { description : _d , shortDescription : _s , ...skill } ) => skill ,
463463 ) ,
464464 }
465465 : provider ,
@@ -2534,6 +2534,9 @@ export const layerWsRpc = (
25342534 if ( instanceId === undefined || cwd === undefined ) {
25352535 return { providers : withoutWorkspaceSnapshots ( commandProviders ) } ;
25362536 }
2537+ const catalogOnDemand =
2538+ input . providerCatalogsOnDemand === true &&
2539+ ( yield * providerInstances . getInstance ( instanceId ) ) ?. snapshotForCwd !== undefined ;
25372540 return {
25382541 providers : commandProviders
25392542 . filter ( ( provider ) => provider . instanceId === instanceId )
@@ -2543,11 +2546,7 @@ export const layerWsRpc = (
25432546 models : [ ] ,
25442547 slashCommands : [ ] ,
25452548 skills : [ ] ,
2546- workspaceSnapshots : workspaceSnapshotOrCatalog (
2547- provider ,
2548- cwd ,
2549- input . providerCatalogsOnDemand === true ,
2550- ) ,
2549+ workspaceSnapshots : workspaceSnapshotOrCatalog ( provider , cwd , catalogOnDemand ) ,
25512550 } ) ) ,
25522551 } ;
25532552 } ) ,
0 commit comments