mirror of
https://github.com/openai/codex.git
synced 2026-06-01 19:02:59 +00:00
Add explicit thread environment selection
Add thread/start environment_id plumbing and explicit local/remote selection support while preserving the current default environment behavior. Include focused exec-server and app-server coverage for the new thread environment selection paths. Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
@@ -430,6 +430,7 @@ pub(crate) struct CodexSpawnArgs {
|
||||
pub(crate) auth_manager: Arc<AuthManager>,
|
||||
pub(crate) models_manager: Arc<ModelsManager>,
|
||||
pub(crate) environment_manager: Arc<EnvironmentManager>,
|
||||
pub(crate) environment_id: Option<String>,
|
||||
pub(crate) skills_manager: Arc<SkillsManager>,
|
||||
pub(crate) plugins_manager: Arc<PluginsManager>,
|
||||
pub(crate) mcp_manager: Arc<McpManager>,
|
||||
@@ -483,6 +484,7 @@ impl Codex {
|
||||
auth_manager,
|
||||
models_manager,
|
||||
environment_manager,
|
||||
environment_id,
|
||||
skills_manager,
|
||||
plugins_manager,
|
||||
mcp_manager,
|
||||
@@ -503,7 +505,7 @@ impl Codex {
|
||||
let (tx_event, rx_event) = async_channel::unbounded();
|
||||
|
||||
let environment = environment_manager
|
||||
.current()
|
||||
.environment(environment_id.as_deref())
|
||||
.await
|
||||
.map_err(|err| CodexErr::Fatal(format!("failed to create environment: {err}")))?;
|
||||
let fs = environment
|
||||
|
||||
Reference in New Issue
Block a user