Propagate remote plugin IDs to skill metadata (#35261)

## What changed

- Carry a plugin's local and remote identities together from plugin loading into
  `SkillMetadata`.
- Resolve remote IDs from the installed-plugin snapshot when available, falling
  back to persisted install metadata only when no snapshot exists.
- Include plugin identity in skill cache keys so identity changes refresh cached
  skill metadata.

## Testing

- Cover snapshot and persisted identity resolution, local marketplace isolation,
  cached skill refreshes, and propagation through plugin skill snapshots.

GitOrigin-RevId: aabeeb631a43361fe817358ace7f1ea8ba5db708
This commit is contained in:
jameswt-oai
2026-07-24 23:36:11 +00:00
committed by copyberry
parent 32329b289d
commit 07fd04abb1
28 changed files with 550 additions and 170 deletions
+8 -1
View File
@@ -26,10 +26,17 @@ pub enum SkillDiscoveryMode {
DirectChildren,
}
/// The local identifier and optional remote identifier for a plugin.
#[derive(Debug, Clone, PartialEq, Eq, Hash)]
pub struct PluginIdentity {
pub plugin_id: String,
pub remote_plugin_id: Option<String>,
}
#[derive(Debug, Clone, PartialEq, Eq, Hash)]
pub struct PluginSkillRoot {
pub path: AbsolutePathBuf,
pub plugin_id: String,
pub plugin_identity: PluginIdentity,
pub plugin_namespace: String,
pub plugin_root: AbsolutePathBuf,
pub discovery_mode: SkillDiscoveryMode,