fix(tui): surface bg job completions as alert notes with attention - #64
Merged
Conversation
A finished background job surfaced as a 3-second transient note on a 10-second poll cadence — practically invisible, as demonstrated live when a GoReleaser watch completed unnoticed. Exit transitions now post alert-tier notes (10s dwell) that name the command head, and fire the attention layer (bell / OSC 9 desktop notification, user-gated as for turns) so the operator is actually told. Clean exits announce '✓ bg job done'; failed, timed-out, and killed jobs announce '✗ bg job failed'.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem (observed live)
A background
gh pr checks --watchjob finished; the operator noticed nothing. Root cause: the jobs watcher's exit note was transient tier (3s dwell) on a 10s poll cadence, with no command context and no bell/notification — a ~3s visibility window starting up to 10s late.Changes
✓ bg_… · gh pr checks 63 --watch — exited 0 · 1m44sattentionJobDone/attentionJobFailedkinds — window-title flash + bell (--belgate) + OSC 9 desktop notification (--notifygate), same machinery as approval/turn-done.failed/timeout/killed→ ✗, clean exit → ✓Not here (by design)
Output tail in the exit note —
/api/jobsexposes nooutput_bytesand output cursors only read forward from byte 0, so clients can't reach the tail without following the stream. Spec written for an odek session:TEMP_ODEK_JOBS_TAIL_TASK.md(untracked, bodek-writes-specs convention).Testing
jobs_notify_test.go): alert-tier dwell, command context, attention-on-transition (nil on steady state), kind mapping + user gatesgo vetclean; fullgo test -race ./...green