From 35f9c640eea3b788209d5afdcf6c29fd06da2aa9 Mon Sep 17 00:00:00 2001 From: Ben Brandt Date: Fri, 20 Feb 2026 11:52:58 +0100 Subject: [PATCH] agent: Change max subagent depth to 1 for now (#49704) There are some UI concerns, especially for permission requests, that get extremely complicated for recurisve subagents. We'll move this to 1 for now to reduce complexity, and revisit once we have a better way for representing all current permission requests. Release Notes: - N/A --- crates/agent/src/thread.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/agent/src/thread.rs b/crates/agent/src/thread.rs index 2700235be77e624ba2944215924da95c6bffd17e..f48e11d6c09da2a3ed3286b7f68b6b59f03fdb51 100644 --- a/crates/agent/src/thread.rs +++ b/crates/agent/src/thread.rs @@ -60,7 +60,7 @@ use uuid::Uuid; const TOOL_CANCELED_MESSAGE: &str = "Tool canceled by user"; pub const MAX_TOOL_NAME_LENGTH: usize = 64; -pub const MAX_SUBAGENT_DEPTH: u8 = 4; +pub const MAX_SUBAGENT_DEPTH: u8 = 1; /// Context passed to a subagent thread for lifecycle management #[derive(Clone, Debug, Serialize, Deserialize)]