Harden marketplace listing and debug smoke errors

This commit is contained in:
npc0-hue
2026-08-22 22:31:33 +08:00
parent ebd616c549
commit 4d945eb809
3 changed files with 38 additions and 3 deletions
+7
View File
@@ -1532,6 +1532,13 @@ func (svc *CoreService) ListMarketplacePlugins(filter domain.PluginMarketplaceFi
if filter.Keyword != "" && !marketplacePluginMatchesKeyword(projected, filter.Keyword) {
continue
}
// The registry can outlive a manifest contract. Do not let a historical
// plugin with removed capabilities make the usable marketplace entries
// fail as one invalid response; it is still available through the plugin
// registry for an explicit refresh or migration.
if err := validator.ValidatePluginMarketplacePlugin(projected); err != nil {
continue
}
items = append(items, projected)
}
if err := validator.ValidatePluginMarketplacePlugins(items); err != nil {