mirror of
https://github.com/openai/codex.git
synced 2026-09-15 12:08:01 +00:00
Fix collab tools at max agent depth
This commit is contained in:
@@ -5,6 +5,7 @@ pub(crate) mod status;
|
||||
|
||||
pub(crate) use codex_protocol::protocol::AgentStatus;
|
||||
pub(crate) use control::AgentControl;
|
||||
#[cfg(test)]
|
||||
pub(crate) use guards::MAX_THREAD_SPAWN_DEPTH;
|
||||
pub(crate) use guards::exceeds_thread_spawn_depth_limit;
|
||||
pub(crate) use guards::next_thread_spawn_depth;
|
||||
|
||||
@@ -10,8 +10,8 @@ use crate::CodexAuth;
|
||||
use crate::SandboxState;
|
||||
use crate::agent::AgentControl;
|
||||
use crate::agent::AgentStatus;
|
||||
use crate::agent::MAX_THREAD_SPAWN_DEPTH;
|
||||
use crate::agent::agent_status_from_event;
|
||||
use crate::agent::exceeds_thread_spawn_depth_limit;
|
||||
use crate::analytics_client::AnalyticsEventsClient;
|
||||
use crate::analytics_client::build_track_events_context;
|
||||
use crate::compact;
|
||||
@@ -274,7 +274,7 @@ impl Codex {
|
||||
}
|
||||
|
||||
if let SessionSource::SubAgent(SubAgentSource::ThreadSpawn { depth, .. }) = session_source
|
||||
&& depth >= MAX_THREAD_SPAWN_DEPTH
|
||||
&& exceeds_thread_spawn_depth_limit(depth)
|
||||
{
|
||||
config.features.disable(Feature::Collab);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user