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

Graceful retry after API errors #245

Open
stigok opened this issue Mar 4, 2024 · 1 comment
Open

Graceful retry after API errors #245

stigok opened this issue Mar 4, 2024 · 1 comment
Labels
bug Something isn't working github-store

Comments

@stigok
Copy link
Contributor

stigok commented Mar 4, 2024

If the GitHub credentials are invalid, the API will be spammed with requests until it will succeed again. That will probably never happen.

s	{"err": [{"error": "GET https://api.github.com/rate_limit: 401 Bad credentials []"}]}
1.7095442091525905e+09	warn	github store	github/github.go:247	failed to get rate limit status	{"err": [{"error": "GET https://api.github.com/rate_limit: 401 Bad credentials []"}]}
1.7095442091993673e+09	warn	github store	github/github.go:247	failed to get rate limit status	{"err": [{"error": "GET https://api.github.com/rate_limit: 401 Bad credentials []"}]}
1.7095442092015991e+09	warn	github store	github/github.go:247	failed to get rate limit status	{"err": [{"error": "GET https://api.github.com/rate_limit: 401 Bad credentials []"}]}
1.7095442092082374e+09	warn	github store	github/github.go:247	failed to get rate limit status	{"err": [{"error": "GET https://api.github.com/rate_limit: 401 Bad credentials []"}]}
1.7095442092203035e+09	warn	github store	github/github.go:247	failed to get rate limit status	{"err": [{"error": "GET https://api.github.com/rate_limit: 401 Bad credentials []"}]}

This might just be the rate limit checker

@stigok
Copy link
Contributor Author

stigok commented Mar 4, 2024

Other code paths seem to fail once and retry later on when they are next invoked

1.709544103457516e+09	error	terraform-registry/main.go:293	failed to reload GitHub store cache	{"err": [{"error": "GET https://api.github.com/search/repositories?per_page=100&q=org%3A%22nrkno%22+topic%3A%22terraform-module%22: 401 Bad credentials []"}]}

@stigok stigok added bug Something isn't working github-store labels Mar 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working github-store
Projects
None yet
Development

No branches or pull requests

1 participant