重构: tool_registry拆分及多批改进

This commit is contained in:
2026-06-19 00:10:14 +08:00
parent a2871a66e0
commit 60b01d03ee
33 changed files with 703 additions and 247 deletions

View File

@@ -4,10 +4,7 @@ version = "0.1.0"
edition = "2021"
[dependencies]
df-types = { path = "../df-types" }
serde = { workspace = true }
serde_json = { workspace = true }
tokio = { workspace = true }
async-trait = { workspace = true }
anyhow = { workspace = true }
tracing = { workspace = true }

View File

@@ -99,7 +99,7 @@ pub async fn execute(request: ShellRequest) -> anyhow::Result<ShellResult> {
cmd.output(),
)
.await
.map_err(|_| anyhow::anyhow!("命令执行超时: {}", secs))??,
.map_err(|_| anyhow::anyhow!("命令执行超时({}s): {}", secs, request.command))??,
None => cmd.output().await?,
};