mirror of
https://github.com/openai/codex.git
synced 2026-10-20 17:38:45 +00:00
Acquire and cache opt-in executor capability inventories via V2 (#53736)
## What changed - Add the disabled-by-default `executor_capability_discovery_v2` feature to acquire `capabilities/discoverV2` inventories from supporting remote executors using each selected environment's working directory and sandbox. - Share snapshots with MCP and world-state contributors and skill providers without activating discovered plugins or publishing discovered skills to the model. - Cache inventories by environment instance, executor session, working directory, and sandbox. Coalesce concurrent requests, refresh the cache at turn start, retry transient failures, and refresh MCP projections after recovery. - Resolve the system skills root in the executor and pass it explicitly to capability location discovery. ## Testing Add coverage for feature gating, unsupported executors, inert inventories, cache reuse and eviction, turn refreshes, failure recovery, executor replacement, and system skill locations. GitOrigin-RevId: 1bdca28fa7f17622b27e2713ab3dcc0c13426889
This commit is contained in:
committed by
copyberry
parent
4d82d36ccf
commit
cf0ed4c600
@@ -1,19 +1,22 @@
|
||||
//! Plugin catalog listing interface and the MCP context used to request snapshots.
|
||||
//! Plugin catalog listing interface and source inputs used to request snapshots.
|
||||
|
||||
use crate::ExecutorPluginProviderError;
|
||||
use crate::PluginCatalog;
|
||||
use codex_exec_server::ExecutorCapabilityDiscoveryV2Snapshot;
|
||||
use codex_mcp::McpResourceClient;
|
||||
use std::future::Future;
|
||||
use std::pin::Pin;
|
||||
use std::sync::Arc;
|
||||
use thiserror::Error;
|
||||
|
||||
/// Turn identifiers and MCP client used to request one catalog snapshot.
|
||||
/// Identifiers, MCP client, and executor inventories used to request one catalog snapshot.
|
||||
#[derive(Clone, Debug)]
|
||||
pub struct PluginListQuery {
|
||||
pub thread_id: String,
|
||||
pub turn_id: String,
|
||||
pub mcp_resources: Option<Arc<McpResourceClient>>,
|
||||
/// Already-acquired V2 inventories; empty for cloud listing.
|
||||
pub snapshots: Vec<ExecutorCapabilityDiscoveryV2Snapshot>,
|
||||
}
|
||||
|
||||
/// Failure to list plugin metadata.
|
||||
|
||||
Reference in New Issue
Block a user