소스 검색

migration: github: if rate limit is not enabled, ignore it (#15490)

tags/v1.15.0-rc1
6543 3 년 전
부모
커밋
2a42d80d14
No account linked to committer's email address
1개의 변경된 파일5개의 추가작업 그리고 0개의 파일을 삭제
  1. 5
    0
      modules/migrations/github.go

+ 5
- 0
modules/migrations/github.go 파일 보기

@@ -132,6 +132,11 @@ func (g *GithubDownloaderV3) sleep() {
func (g *GithubDownloaderV3) RefreshRate() error {
rates, _, err := g.client.RateLimits(g.ctx)
if err != nil {
// if rate limit is not enabled, ignore it
if strings.Contains(err.Error(), "404") {
g.rate = nil
return nil
}
return err
}


Loading…
취소
저장