app ui: a finished job's banner stays 5 minutes when it succeeded, 30 when it failed

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
igneum-labs 2026-10-05 07:50:57 +00:00
parent b243ed7e95
commit 9aa5d5da24

View file

@ -768,8 +768,8 @@
}
var l = j.last;
if (!l || !l.id) return null;
// the last outcome stays up for 30 minutes
if (l.finished_at && now - l.finished_at > 1800) return null;
// the last outcome stays up for 5 minutes when it succeeded, 30 minutes when it failed (hide dismisses it at once)
if (l.finished_at && now - l.finished_at > (l.status === 'done' ? 300 : 1800)) return null;
var d = Math.max(0, Math.round((l.finished_at - l.started_at) / 60));
return { text: 'Job: ' + (l.title || l.kind) + ' ' + l.status + ' after ' + d + ' min, exit ' + l.exit + (l.uploaded ? ', report uploaded' : ', report not uploaded') + (l.summary ? '. ' + l.summary : ''), results: j.last_results || [], failed: l.status !== 'done' };
}