Skip to content

feat(report): add a runner watchdog that toasts an offline runner or a long queue - #17

Merged
Nain9Dev merged 1 commit into
mainfrom
feat/runner-watch
Oct 15, 2026
Merged

Nain9Dev merged 1 commit into
mainfrom
feat/runner-watch

Conversation

@Nain9Dev

Copy link
Copy Markdown
Member

Summary

The weekly report says how the queue behaved over a period; nothing said that it was wrong now. A
runner that falls off the VM, or a run stuck for an hour, was found by whoever noticed.

report/runner_watch.py reads, over gh, the runners of the organisation and of each private
repository in it, plus the runs still queued, and raises one toast per finding through the desktop's
own notify.ps1:

  • a runner offline for --offline-min minutes (default 10); GitHub does not say since when, so the
    first sighting is remembered in a state file;
  • a run queued for --queue-min minutes (default 15).

A finding is reported once, and again only after it has cleared. --ignore NAME mutes a runner that is
offline on purpose. An unreadable answer (a 403, a network blip) is skipped, never reported.

Verification

  • tests/test_runner_watch.py: 20 tests (thresholds, once-only, recovery, ignore, collection with a
    broken endpoint, the real commands, toasts, state file); 166 tests pass together; ruff clean.
  • Run once against the real organisation with zero thresholds and no toast: it found exactly one
    offline runner (contrast-viewer-vm-02, retired on purpose) and no queued run.

Notes

  • Registering it as a scheduled task on the desktop is a separate step for the owner
    (workstation-maintenance).

…a long queue

The weekly report says how the queue behaved; nothing said that it was
wrong now. runner_watch.py reads the runners of the organisation and of
each private repository plus the queued runs, and reports a runner seen
offline for 10 minutes (the first sighting is remembered, GitHub does not
say since when) or a run queued for 15, once per finding, through the
desktop's notify.ps1. An ignored runner or an unreadable answer raises
nothing.
@Nain9Dev
Nain9Dev merged commit 333a114 into main Oct 15, 2026
5 checks passed
@Nain9Dev
Nain9Dev deleted the feat/runner-watch branch October 15, 2026 13:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant