Repository navigation
Pause GitHub repository traffic collection - #572
Merged
Alejandro Lopez (soyalejolopez) merged 1 commit intoOct 29, 2026
Merged
Alejandro Lopez (soyalejolopez) merged 1 commit into
Alejandro Lopez (soyalejolopez) merged 1 commit into
Conversation
The step needs a token with Administration read access, which organization policy expires every few days, so it failed daily and kept issue microsoft#482 open. It now runs only when the COLLECT_GITHUB_TRAFFIC repository variable is true and otherwise emits a notice. Clarity and vote collection, staging, and the weekly pull request are unchanged, and the workflow test now models a skipped step. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Alejandro Lopez (soyalejolopez)
merged commit Oct 29, 2026
71e6609
into
microsoft:master
5 checks passed
This was referenced Oct 29, 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.
Category
What's in this pull request?
Pauses the GitHub repository traffic step in the daily Collect Traffic Data workflow, so the run stops failing and issue #482 can close.
That step reads GitHub's traffic API (views, clones, referrers, popular paths, stars and forks), which needs a token with Administration read access. Organization policy limits fine-grained tokens to a few days, so the step has failed every day since 2026-07-22 and its alert issue (#482) has collected 100 daily "Still failing" comments. The data is not used by the site: card view counts come from Clarity (
resource-stats.jsonrecords"views": "clarity"), and upvotes come from GitHub Discussions.What changed
traffic-stats.yml: the GitHub traffic step now runs only when the repository variableCOLLECT_GITHUB_TRAFFICistrue. When it is not, a notice step says collection is paused and how to resume. The Clarity and vote collection, staging, and weekly pull request are unchanged. A skipped step is neither a success nor a failure, so the existing conditions keep the run green when Clarity is healthy and still fail it when Clarity or staging is not. The alert step only fires on a failed GitHub step, so it stays quiet.COLLECT_GITHUB_TRAFFICtotrueand replace theTRAFFIC_TOKENsecret.test-traffic-workflow.js: models the skipped state (it only knew success and failure), adds three combinations (paused with healthy Clarity stays green and persisted; paused with unhealthy Clarity or a staging failure still fails), and checks that the gate and the notice exist and that the notice is not an error.traffic-data/README.mdandCHANGELOG.mdexplain the pause and how to resume.After merge: close #482. The daily run no longer comments on it.
Trade-off: GitHub keeps only 14 days of repository traffic, so views, clones and referrers are not recorded while paused. Clarity page analytics, which cover the GitHub Pages site, are unaffected.
Related issues
Closes #482 once merged and confirmed green.
Checklist
npm ci --prefix tools/catalog-build && npm run check --prefix tools/catalog-build(passes)versionandupdatedwere bumped (not applicable: no resource changed)See CONTRIBUTING.md for details.