Skip to content

HarnessRouter Community Edition: the self-hosted, Apache-2.0 edition of the unified interface for agent harnesses. Run Codex, Claude Code, Hermes, PI, DSH, and more through one API, with sessions, streaming, files, cancellation, and failure handling. Implements the Unified Harness Protocol (UHP), an open standard. Your keys, your infrastructure.

fix(harnesses): the task header's latency falls back to the record's own elapsed

richard-epsilla3df855c49643
diff --git a/ui/src/app/(app)/harnesses/page.tsx b/ui/src/app/(app)/harnesses/page.tsx
index 72fb5244..53a4313a 100644
--- a/ui/src/app/(app)/harnesses/page.tsx
+++ b/ui/src/app/(app)/harnesses/page.tsx
@@ -247,8 +247,12 @@ export default function HarnessesPage() {
const credits = card?.credits != null && card.credits > 0 ? card.credits
: totals && totals.costed > 0 ? totals.credits : null;
const creditsPartial = !(card?.credits != null && card.credits > 0) && !!totals && totals.costed < totals.finished;
- const latency = totals && totals.timed > 0 ? totals.elapsed : null;
- const latencyPartial = !!totals && totals.timed < totals.finished;
+ // This box's gateway stamps elapsed on the task record, not (yet) on each
+ // turn — so when no turn carries latency, the record's own total is the truth,
+ // same preference order the credits line above already uses.
+ const latency = totals && totals.timed > 0 ? totals.elapsed
+ : card?.elapsed != null && card.elapsed > 0 ? card.elapsed : null;
+ const latencyPartial = !!totals && totals.timed > 0 && totals.timed < totals.finished;
if (credits == null && latency == null) return null;
return (
<span className="hx-badges" aria-label="Task totals">