diff --git a/docs/tools/subagent.md b/docs/tools/subagent.md index 6dc02208..ca2c0e7c 100644 --- a/docs/tools/subagent.md +++ b/docs/tools/subagent.md @@ -71,7 +71,7 @@ turn's end-of-turn todo, carrying claude's own message plus the location this daemon searched. ``` -claude error: no session matched the requested id or title (searched /home/agent/.claude for cwd /home/agent/work; if the session was started elsewhere, pass `dir`) +claude error: no session matched the requested id or title (searched /home/agent/.claude for cwd /home/agent/work; if it was started elsewhere, pass the `dir` it was started in) ``` The directory is the part claude's own message never names, and the part diff --git a/hive-subagent-mcp/src/session.rs b/hive-subagent-mcp/src/session.rs index d81e13bc..9ae11203 100644 --- a/hive-subagent-mcp/src/session.rs +++ b/hive-subagent-mcp/src/session.rs @@ -130,7 +130,7 @@ fn searched_location(config: &Config) -> Option { let home = config.resolved_claude_home().ok()?; let cwd = config.resolved_cwd().ok()?; Some(format!( - "(searched {} for cwd {}; if the session was started elsewhere, pass `dir`)", + "(searched {} for cwd {}; if it was started elsewhere, pass the `dir` it was started in)", home.display(), cwd.display() )) @@ -1410,8 +1410,8 @@ mod tests { // where this daemon looked. claude's own message names the value it // failed to match but never the directory, which is the fact that // was missing. - let searched = "(searched /home/agent/.claude for cwd /home/agent/work; if the session \ - was started elsewhere, pass `dir`)"; + let searched = "(searched /home/agent/.claude for cwd /home/agent/work; if it was started \ + elsewhere, pass the `dir` it was started in)"; let end = classify_end(Err(hive_claude::Error::SessionNotFound), Some(searched)); let TurnEnd::Failed(msg) = end else { panic!("a missed resume is a failed turn"); @@ -1425,7 +1425,7 @@ mod tests { "and the search location must be appended to it: {msg}" ); assert!( - msg.contains("pass `dir`"), + msg.contains("pass the `dir` it was started in"), "naming the directory is only half of it — say what to do about it: {msg}" ); }