loopd: a failed heartbeat still advances last_heartbeat

Co-Authored-By: ornith-1.5-35b-a3b <agent@wntrmute.dev>
This commit is contained in:
2026-10-03 18:24:18 -07:00
co-authored by ornith-1.5-35b-a3b
parent 3940588ce7
commit 30608995ca
3 changed files with 54 additions and 5 deletions
+3 -5
View File
@@ -252,7 +252,7 @@ impl Scheduler {
let text = format!("It is {}.\n\n{file}", now.to_rfc3339());
let mut emit = |_event: &TurnEvent| {};
let outcome = run_turn(&mut session, &runtime, &text, None, &mut emit);
let outcome = compact::finish_turn(
let _ = compact::finish_turn(
&mut session,
&runtime,
&*ctx.memory,
@@ -261,11 +261,9 @@ impl Scheduler {
&mut emit,
outcome,
);
if outcome.is_ok() {
self.last_heartbeat = Some(now);
work.push(TickWork::Heartbeat);
}
drop(held);
self.last_heartbeat = Some(now);
work.push(TickWork::Heartbeat);
}
}