Skip to content

[Bug]: Contributor Profile Shows Pull Requests From All GitHub Repositories #628

@mayurigade-hub

Description

@mayurigade-hub

What is happening?
The contributor profile page fetches pull requests using:

author:${username}+type:pr

This shows PRs made by the user across all GitHub repositories, not only this project.

Why is this a problem?
A user opens a contributor profile from this project’s Contributors page, so they expect to see that person’s pull requests for this repository. Showing unrelated PRs from other repositories can be confusing and makes the profile data inaccurate.

How to fix it:
Update the GitHub search query to include the project repository name.

Example:

https://api.github.com/search/issues?q=repo:GitMetricsLab/github_tracker+author:${username}+type:pr

Steps to Reproduce:

  1. Open the Contributors page.
  2. Click on any contributor profile.
  3. Check the Pull Requests section.
  4. Notice that PRs from other repositories can appear, not only PRs from GitMetricsLab/github_tracker.

Files affected:
src/pages/ContributorProfile/ContributorProfile.tsx
src/utils/constants.ts optional, if the repo name is moved into a reusable constant.

Metadata

Metadata

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions