huskies: merge 882

This commit is contained in:
dave
2026-04-30 00:31:08 +00:00
parent a796bd933f
commit b0de86767a
7 changed files with 173 additions and 3 deletions
+5 -2
View File
@@ -399,14 +399,16 @@ fn run_agent_pty_blocking(
let _ = child.kill();
let wait_result = child.wait();
match &wait_result {
let exit_ok = match &wait_result {
Ok(status) => {
slog!("[agent:{story_id}:{agent_name}] Child exited: {status:?}");
status.success()
}
Err(e) => {
slog!("[agent:{story_id}:{agent_name}] Child wait error: {e}");
false
}
}
};
// Wait for the reader thread to finish so it releases the cloned PTY
// master fd before we return. Without this, the next PTY spawn for the
@@ -434,5 +436,6 @@ fn run_agent_pty_blocking(
Ok(PtyResult {
session_id,
token_usage,
exit_ok,
})
}
+3
View File
@@ -10,6 +10,9 @@ use crate::agents::TokenUsage;
pub(in crate::agents) struct PtyResult {
pub session_id: Option<String>,
pub token_usage: Option<TokenUsage>,
/// `true` if the child process exited with a zero exit code (normal completion).
/// `false` if the process was killed by a signal or exited with a non-zero code.
pub exit_ok: bool,
}
pub(super) fn composite_key(story_id: &str, agent_name: &str) -> String {