huskies: merge 877

This commit is contained in:
dave
2026-04-29 22:04:47 +00:00
parent 7e2f122d36
commit e56bd2d834
4 changed files with 260 additions and 63 deletions
+16 -5
View File
@@ -15,11 +15,22 @@ pub(crate) async fn tool_start_agent(args: &Value, ctx: &AppContext) -> Result<S
let agent_name = args.get("agent_name").and_then(|v| v.as_str());
let project_root = ctx.services.agents.get_project_root(&ctx.state)?;
let info = ctx
.services
.agents
.start_agent(&project_root, story_id, agent_name, None, None)
.await?;
// When an explicit agent_name is provided, persist the agent pin in the
// CRDT register before starting — same path as the Matrix `assign` command.
let info = if let Some(name) = agent_name {
crate::service::work_item::assign_and_start(
story_id,
name,
&project_root,
&ctx.services.agents,
)
.await?
} else {
ctx.services
.agents
.start_agent(&project_root, story_id, None, None, None)
.await?
};
// Snapshot coverage baseline from the most recent coverage report (best-effort).
if let Some(pct) = read_coverage_percent_from_json(&project_root)