Skip to content

Commit 93054bc

Browse files
committed
refactor(diagnostic): early-return passive heartbeat progress
1 parent 6b4d263 commit 93054bc

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

src/logging/diagnostic-run-activity.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -276,14 +276,14 @@ function isPassiveRunProgressReason(reason: string): boolean {
276276
}
277277

278278
export function markDiagnosticRunProgress(params: DiagnosticRunProgressActivityEvent): void {
279-
const passiveProgress = isPassiveRunProgressReason(params.reason);
280-
const activity = resolveSessionActivity({ ...params, create: !passiveProgress });
281-
if (!activity) {
279+
// Claude live active-tool heartbeats are observability ticks, not work progress.
280+
// Refreshing the session clock (or even creating activity) here can hide wedged
281+
// CLI tools from stall detection.
282+
if (isPassiveRunProgressReason(params.reason)) {
282283
return;
283284
}
284-
if (passiveProgress) {
285-
// Claude live active-tool heartbeats are observability ticks, not work progress.
286-
// Refreshing the session clock here can hide wedged CLI tools from stall detection.
285+
const activity = resolveSessionActivity({ ...params, create: true });
286+
if (!activity) {
287287
return;
288288
}
289289
touchSessionActivity(activity, params.reason);

0 commit comments

Comments
 (0)