Copilot remains in repository Contributors sidebar after cleanup, but not in contributors API #209992
Replies: 5 comments
|
The mismatch is expected while GitHub refreshes contributor data after a history rewrite. GitHub’s documentation says contributor displays and statistics can take about 24 hours after force-pushing, rewriting history, or deleting commits, and the contributors API itself may return cached data. Because the API and the current default-branch history already omit Copilot, I would not rename the default branch as a first-line workaround; that creates an unnecessary repository-wide ref change and is not the documented refresh mechanism. Keep References: https://docs.github.com/en/repositories/viewing-activity-and-data-for-your-repository/viewing-a-projects-contributors and https://docs.github.com/en/rest/repos/repos#list-repository-contributors. If this resolves the question, please click Mark as answer. |
|
Thanks for the explanation. The issue has already persisted for more than 48 hours after the history cleanup. The repository homepage sidebar still lists Copilot, while the current main history and contributors API omit Copilot. I contacted GitHub Support, but the ticket was closed with a note that my account only has self-service support options. Could a GitHub Community maintainer confirm whether the homepage Contributors panel has a separate refresh/recalculation path, or advise how this discrepancy can be escalated? I can attach the screenshot showing the sidebar if useful. I will leave the default branch and commit history unchanged for now rather than rename branches or force-push again. |
|
The sidebar has its own cached list, separate from /contributors, and it isn't recalculated just because time passes. What forces a recalculation is a change to the default branch. Here are two low-risk ways to trigger one, mildest first: Push a new commit to the default branch (any trivial change). It's harmless, and community reports say it sometimes refreshes the list. |
|
The fact that the Contributors API and the current I'd also check whether there are other reachable branches or tags that still contain the old history. If the unwanted attribution is absent from every relevant ref and the API but still appears in the UI across devices, I'd report it to GitHub Support with the repository URL, current commit SHA, API result, and screenshots. I wouldn't recommend rewriting history again just to fix the sidebar. That introduces risk without establishing that the Git data is still the problem. |
|
Hello, I'm experiencing the same issue with my repository. Repository: https://github.com/IrafashCactus/auspify-netflix-data-science The Insights → Contributors graph shows only @IrafashCactus, and the Contributors API returns my account with four contributions. The default branch history also contains only commits authored and committed by me, with no Copilot co-author trailers. However, the repository homepage still shows Could someone help refresh or recalculate the repository homepage's contributor list? I would prefer not to rewrite my commit history again because the graph and API already appear correct. Thank you. |
Uh oh!
There was an error while loading. Please reload this page.
🏷️ Discussion Type
Question
Body
Hi everyone,
I cleaned up the commit history for https://github.com/Jhunkcion/Crevia more than two days ago, but the repository homepage sidebar still lists Copilot under Contributors. It appears the same on multiple devices.
The default branch is main at 5f079cb9bfa61e84ac46f2abf66c71442e43b4bc. The contributors API currently lists ichsanallfa, Jhunkcion, and KingRudolf222, but not Copilot: https://api.github.com/repos/Jhunkcion/Crevia/contributors?per_page=100. I also checked all 24 commits on main; none has Copilot as author or a Co-authored-by trailer.
I found the pinned discussion https://github.com/orgs/community/discussions/209302, which mentions stale contributors after history rewrites and a workaround involving renaming the default branch and renaming it back. Another discussion, https://github.com/orgs/community/discussions/190363, discusses removing AI/bot contributors by rewriting the affected commit author. In this repo, however, the active main history and contributors API no longer show Copilot.
Is renaming the default branch and then changing it back a safe/recommended way to refresh the homepage contributor list in this situation? Is there another way to refresh it, given the mismatch with the API?
Thanks!
All reactions