fix(ci): correct the Hacktoberfest tracker's open-issue count and add a countdown - #15235
Merged
cclauss merged 2 commits intoSep 9, 2026
Merged
Conversation
The tracker's "Open issues" line was showing the pull-request total (e.g.
621) instead of the issue total (107). GitHub's `/search/issues`
`is:issue` / `is:pr` qualifiers are unreliable on this large, high-churn
repo -- some runs return the PR pool for *both* queries, so the two lines
printed the same number.
Count without the flaky qualifiers instead:
- open PRs = the `Link: rel="last"` page number of `/repos/{repo}/pulls`
(deterministic, page-numbered pagination);
- open issues = the repo endpoint's `open_issues_count` (issues + PRs)
minus the open-PR total -- self-checking and stable.
Also add the requested Hacktoberfest countdown to the stats block:
- days until 2026-10-01;
- issues to close per day to clear the backlog;
- PRs to merge or close per day to clear the backlog.
Per-day figures round up (finishing a day early beats a day late) and
degrade to a clear message once Hacktoberfest starts, so the block never
divides by zero on the final day.
15 tasks
cclauss
approved these changes
Sep 9, 2026
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.
@cclauss — this addresses both of your review notes.
Not an algorithm change — this is a CI/tracker fix, so the algorithm-specific checkboxes below don't apply. Marking the ones that do so the keeper doesn't auto-close it again.
The 621 bug
docs/hacktober_2026_prep.mdreported Open issues: 621 when the repo has 107. Root cause: GitHub's/search/issuesis:issue/is:prqualifiers are unreliable on a repo this large and high-churn — some runs return the pull-request pool for both queries, which is why "Open issues" and "Open pull requests" printed the same number (621).I replaced the two search calls with deterministic ones:
Link: rel="last"page number of/repos/{repo}/pulls?state=open&per_page=1(that endpoint still uses page-numbered pagination, so the last page number is the count);open_issues_count(which counts issues and PRs) minus the open-PR total. Self-checking: 728 − 621 = 107. ✅(The
awaiting reviewsline still uses search; I paginated it fully and confirmed 458 is the true count, so I left it — happy to harden it the same way if you'd like.)New Hacktoberfest countdown
Added the three metrics you asked for to
## Automated statistics:Per-day numbers round up (finishing a day early beats a day late) and degrade to a plain message once Hacktoberfest starts, so the block never divides by zero on the final day.
Live output (regenerated into the doc)
ruff check,ruff format --check, andty checkall pass. Verified the new counters against the live API before committing.Describe your change:
Fixes the Hacktoberfest prep tracker's
Open issuescount (was echoing the PR count, now deterministic) and adds the three requested countdown metrics. Touchesscripts/hacktoberfest_prep_update.pyand the generateddocs/hacktober_2026_prep.md.Checklist: