You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
controller: /healthz should not name unreadable scopes #51
/healthz is public and lists every unreadable scope by name in unreadable_scopes. When a private repository in RUNNER_SCOPES cannot be read, anyone who calls the endpoint learns that repository's name. The same names also tend to get copied into public issues from the health body.
Change:
/healthz reports only the number of unreadable scopes (for example unreadable_scopes: 3), never their names.
The names stay in the controller's own logs and in the failing alert, which only the operator sees.
Update README and CHANGELOG for the new field shape.
Done when: with an unreadable scope configured, /healthz shows the count and no repository name, a test covers it, and the log line still names the scope.
Note: PR #50 also changes how 404 scopes are reported; build on top of it or after it merges.
Plan for this one. It builds on #50 (branch fix/49-not-found-scopes), so the PR will target that branch and move to main once #50 merges.
Approach:
HealthHandler writes unreadable_scopes as a number, len(Status.UnreadableScopes), instead of the list of names. Status keeps the names in memory; nothing outside the process reads it.
Logs and alerts stay as they are: a 404 scope still logs scope not found on GitHub; skipped with scope=<name>, other read errors still log cycle failed with the scope in the error, and the failing and missing-scope alerts still name scopes (they go only to the operator's webhook).
README (/healthz paragraph and troubleshooting row) and CHANGELOG [Unreleased] describe unreadable_scopes as a count, and say the names are in the logs.
Invariants:
/healthz status codes and every other field stay the same.
No scope or repository name appears anywhere in the /healthz body (error is already a bool, not the error text).
Tests:
A 404 scope beside a readable one: /healthz has unreadable_scopes: 1, the body contains no scope name, and the warn log line still names the scope.
A scope failing for another reason: /healthz has the count and no name, and the failing alert still names it.
The existing tests that compared unreadable_scopes to a list of names change to compare the count.
Breaking for anyone who parses unreadable_scopes as a list; CHANGELOG says so.
Started. The failing test is on branch fix/51-healthz-scope-count in draft PR #52 (it targets #50's branch). Next: make /healthz report the count, then update README and CHANGELOG.
PR #52 is ready for review. /healthz now reports unreadable_scopes as a count and never names a scope; the log lines and alerts still name them. Tests, vet and the quality gates pass locally (details in the PR). It targets #50's branch, so #50 merges first. Waiting on review.
PR #52 closed without merging when #50 merged and its base branch was deleted, so this is not on main. Branch fix/51-healthz-scope-count still holds the work (43e8d4a) but sits on #50's pre-squash commits. Next: rebase it onto main (7969a10) and open a new PR against main. Work has started on this.
Rebased the work onto main as branch fix/51-healthz-unreadable-count, now in draft PR #53 against main. Next: run the tests and quality gates again on the rebased code, then mark it ready.
PR #53 is ready for review. It holds the same change as #52, rebased onto main: /healthz reports unreadable_scopes as a count and never names a scope, while the log lines and alerts still name them. On the rebased code, vet, gofmt and go test -race pass. CRAP is 5 and 6 on the changed functions, dryer finds no duplicates, and the mutator killed all 7 mutants. The new test fails against main's code. Waiting on review.
Activity
parsilver commentedon Nov 19, 2026
Plan for this one. It builds on #50 (branch
fix/49-not-found-scopes), so the PR will target that branch and move tomainonce #50 merges.Approach:
HealthHandlerwritesunreadable_scopesas a number,len(Status.UnreadableScopes), instead of the list of names.Statuskeeps the names in memory; nothing outside the process reads it.scope not found on GitHub; skippedwithscope=<name>, other read errors still logcycle failedwith the scope in the error, and the failing and missing-scope alerts still name scopes (they go only to the operator's webhook)./healthzparagraph and troubleshooting row) and CHANGELOG[Unreleased]describeunreadable_scopesas a count, and say the names are in the logs.Invariants:
/healthzstatus codes and every other field stay the same./healthzbody (erroris already a bool, not the error text).Tests:
/healthzhasunreadable_scopes: 1, the body contains no scope name, and the warn log line still names the scope./healthzhas the count and no name, and the failing alert still names it.unreadable_scopesto a list of names change to compare the count.Breaking for anyone who parses
unreadable_scopesas a list; CHANGELOG says so.parsilver commentedon Nov 19, 2026
Started. The failing test is on branch
fix/51-healthz-scope-countin draft PR #52 (it targets #50's branch). Next: make/healthzreport the count, then update README and CHANGELOG.parsilver commentedon Nov 19, 2026
PR #52 is ready for review.
/healthznow reportsunreadable_scopesas a count and never names a scope; the log lines and alerts still name them. Tests, vet and the quality gates pass locally (details in the PR). It targets #50's branch, so #50 merges first. Waiting on review.parsilver commentedon Nov 19, 2026
PR #52 closed without merging when #50 merged and its base branch was deleted, so this is not on main. Branch
fix/51-healthz-scope-countstill holds the work (43e8d4a) but sits on #50's pre-squash commits. Next: rebase it onto main (7969a10) and open a new PR against main. Work has started on this.parsilver commentedon Nov 19, 2026
Rebased the work onto main as branch
fix/51-healthz-unreadable-count, now in draft PR #53 against main. Next: run the tests and quality gates again on the rebased code, then mark it ready.parsilver commentedon Nov 19, 2026
PR #53 is ready for review. It holds the same change as #52, rebased onto main:
/healthzreportsunreadable_scopesas a count and never names a scope, while the log lines and alerts still name them. On the rebased code, vet, gofmt andgo test -racepass. CRAP is 5 and 6 on the changed functions, dryer finds no duplicates, and the mutator killed all 7 mutants. The new test fails against main's code. Waiting on review.