Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Site Should Be Able To Render Without External Data #716

Open
sampoder opened this issue Feb 22, 2023 · 8 comments
Open

Site Should Be Able To Render Without External Data #716

sampoder opened this issue Feb 22, 2023 · 8 comments

Comments

@sampoder
Copy link
Member

If the GitHub API goes down, for example, the site should be still be able to load just without the stars or activity showing.

@LassazVegaz
Copy link

Since the PR branch has been deleted, I would like to fix this issue.

@maxwofford
Copy link
Member

Would also like to flag this is happening for preview deploys sometimes #988 (comment)

@maxwofford
Copy link
Member

@LassazVegaz if you can take a crack at this please do! it'd help a bunch

@LassazVegaz
Copy link

@maxwofford sure

@LassazVegaz
Copy link

@maxwofford I can see some places using process.env.GITHUB_TOKEN to fetch data from GitHub Hackclub org. But they are not surrounded by try-catch. So I think if they fail, the site fails too. I can add try-catch and handle the errors without breaking the site, but I won't be able to test it. Is that okay?

If this is not what you want, please point out the places you want me to check.

@maxwofford
Copy link
Member

Shouldn't the result be the same for invalid token and missing token? If we can't pull GH data let's fill those areas on the page with some other placeholder

@LassazVegaz
Copy link

When the token is missing, it does not fetch data. If the token is there, it does not check the validity of the token. Just fetch data. Check fetchStars function and its usage here without Try-Catch which can fail the execution of rest of the code.

@grymmy
Copy link
Contributor

grymmy commented Apr 24, 2024

@LassazVegaz @maxwofford do we plan on moving forward with this change? seems reasonable, but this issue's also been open over a year

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants