Repository navigation
Track PR associations and filter contributor commits - #25
Merged
Merged
Conversation
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.
Contributor commit history currently cannot distinguish commits introduced through a PR from direct pushes. This records GitHub’s
Commit.associatedPullRequestsalongside each credited commit and adds a persisted PR commits only control on Contributors.The filter applies to commit timelines at every granularity, contributor totals/rankings, and repository chart splits. Squash commits are classified using GitHub’s association, rather than commit-message heuristics. It counts commits and credited co-authors, not distinct PRs. The control is available for the Commits metric; line statistics and the weekly repository numbers panel are hidden while filtering because the daily log has no line counts.
Existing databases migrate without losing history: old associations remain NULL, distinct from known direct commits. Commit-log format 3 makes older repositories eligible for Backfill daily commits, now also offered on Contributors. This re-reads full default-branch history only; incremental syncs update associations for fetched commits but cannot mark old history complete. Failed or cancelled repositories can be retried. Users need to run that backfill after installing to populate historical associations; the PR does not run a sync against their local app data.
Validation:
npm run check— passed, including new coverage for migration preservation/idempotence, GraphQL association retrieval, all four filtered query shapes, co-authors, repository/user/date filters, unknown data, and incremental refresh/backfill state.npm run build— passed (existing bundle-size warning).npm run typecheck— passed after final UI edits.GitHub API semantics: https://docs.github.com/en/graphql/reference/commits