What is happening?
When the GitHub API request fails for reasons like rate limit, network error, or server error, the page still shows:
User not found.
Why is this a problem?
This message is misleading. The user may exist, but the app could not load the data. Users will think the GitHub username is wrong when the real problem is an API or connection failure.
How to fix it:
Add a separate error state in ContributorProfile.tsx. Show User not found only for 404, and show a different message for other failures, like:
Unable to load contributor profile. Please try again later.
Steps to Reproduce:
- Open any contributor profile page.
- Block the GitHub API request, disconnect the internet, or hit GitHub rate limits.
- Wait for the page to finish loading.
- The page shows
User not found even though the user may exist.
Files affected:
src/pages/ContributorProfile/ContributorProfile.tsx
What is happening?
When the GitHub API request fails for reasons like rate limit, network error, or server error, the page still shows:
User not found.Why is this a problem?
This message is misleading. The user may exist, but the app could not load the data. Users will think the GitHub username is wrong when the real problem is an API or connection failure.
How to fix it:
Add a separate
errorstate inContributorProfile.tsx. ShowUser not foundonly for404, and show a different message for other failures, like:Unable to load contributor profile. Please try again later.Steps to Reproduce:
User not foundeven though the user may exist.Files affected:
src/pages/ContributorProfile/ContributorProfile.tsx