mirror of
https://github.com/openai/codex.git
synced 2026-11-23 23:10:47 +00:00
Add remote plugin metadata to plugin configuration (#54424)
## What changed Add optional `remote_plugin_id`, `release_id`, and `auto_provision` fields to `PluginConfig` and the configuration schema. Store remote plugin identity, release, and provisioning metadata without fetching releases or triggering provisioning. Entries containing only this metadata continue to inherit existing plugin activation defaults. ## Testing Extend configuration round-trip and plugin loader tests to cover remote metadata entries with inherited enablement and with `plugins._default.enabled = false`. GitOrigin-RevId: bb657c25929cab100982b37120ab62b089eb7044
This commit is contained in:
@@ -377,6 +377,9 @@ fn configured_plugins_from_stack_merges_enabled_effective_layers() {
|
||||
"base".to_string(),
|
||||
PluginConfig {
|
||||
enabled: Some(true),
|
||||
remote_plugin_id: None,
|
||||
release_id: None,
|
||||
auto_provision: None,
|
||||
mcp_servers: HashMap::new(),
|
||||
},
|
||||
),
|
||||
@@ -384,6 +387,9 @@ fn configured_plugins_from_stack_merges_enabled_effective_layers() {
|
||||
"profile".to_string(),
|
||||
PluginConfig {
|
||||
enabled: Some(true),
|
||||
remote_plugin_id: None,
|
||||
release_id: None,
|
||||
auto_provision: None,
|
||||
mcp_servers: project_mcp_servers.clone(),
|
||||
},
|
||||
),
|
||||
@@ -391,6 +397,9 @@ fn configured_plugins_from_stack_merges_enabled_effective_layers() {
|
||||
"system".to_string(),
|
||||
PluginConfig {
|
||||
enabled: Some(true),
|
||||
remote_plugin_id: None,
|
||||
release_id: None,
|
||||
auto_provision: None,
|
||||
mcp_servers: HashMap::new(),
|
||||
},
|
||||
),
|
||||
@@ -622,6 +631,16 @@ enabled = true
|
||||
false,
|
||||
HashMap::new(),
|
||||
),
|
||||
(
|
||||
"[plugins.\"valid@test\"]\nremote_plugin_id = 'remote-plugin-123'\nrelease_id = 'plugin-release-123'\nauto_provision = true",
|
||||
true,
|
||||
HashMap::new(),
|
||||
),
|
||||
(
|
||||
"[plugins._default]\nenabled = false\n[plugins.\"valid@test\"]\nremote_plugin_id = 'remote-plugin-123'\nrelease_id = 'plugin-release-123'\nauto_provision = true",
|
||||
false,
|
||||
HashMap::new(),
|
||||
),
|
||||
] {
|
||||
let stack = ConfigLayerStack::default()
|
||||
.with_user_config(
|
||||
|
||||
Reference in New Issue
Block a user