github icon indicating copy to clipboard operation
github copied to clipboard

Exceeded a secondary rate limit error

Open muratcorlu opened this issue 4 years ago • 0 comments

Recently we hit an error that says

You have exceeded a secondary rate limit. Please wait a few minutes before you try again.

Here is the full log:

2022-09-08T07:08:55.0323010Z [7:08:55 AM] [semantic-release] [@semantic-release/github] › ℹ  Published GitHub release: https://github.com/Trendyol/baklava/releases/tag/v2.0.0-beta.24
2022-09-08T07:08:55.0324305Z [7:08:55 AM] [semantic-release] › ✔  Completed step "publish" of plugin "@semantic-release/github"
2022-09-08T07:08:55.0327721Z [7:08:55 AM] [semantic-release] › ℹ  Start step "success" of plugin "@semantic-release/github"
2022-09-08T07:08:56.1501422Z [7:08:56 AM] [semantic-release] › ✖  Failed step "success" of plugin "@semantic-release/github"
2022-09-08T07:08:56.1540054Z [7:08:56 AM] [semantic-release] › ✖  An error occurred while running semantic-release: RequestError [HttpError]: You have exceeded a secondary rate limit. Please wait a few minutes before you try again.
2022-09-08T07:08:56.1541129Z     at /home/runner/.npm/_npx/cdf31b77322f1d44/node_modules/@octokit/request/dist-node/index.js:88:21
2022-09-08T07:08:56.1541778Z     at processTicksAndRejections (node:internal/process/task_queues:96:5) {
2022-09-08T07:08:56.1542221Z   status: 403,
2022-09-08T07:08:56.1542551Z   response: {
2022-09-08T07:08:56.1544310Z     url: 'https://api.github.com/search/issues?q=repo%3ATrendyol%2Fbaklava+type%3Apr+is%3Amerged+116919c5904430c79d03fb6a5318bedad01ff6c0+04b0023931a27511cd13154811be7d3cbe16f27f+2ad6dfbd6258faf9ae08358a3ad48b96dcd5c714+9fd294cf0ff8aac8cbfd3279f3ff5588420d00a2+75c8ec4eabc331039855982ef9aeca10170ebba4',
2022-09-08T07:08:56.1545489Z     status: 403,
2022-09-08T07:08:56.1545799Z     headers: {
2022-09-08T07:08:56.1546295Z       'access-control-allow-origin': '*',
2022-09-08T07:08:56.1547848Z       'access-control-expose-headers': 'ETag, Link, Location, Retry-After, X-GitHub-OTP, X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, Sunset',
2022-09-08T07:08:56.1548832Z       connection: 'close',
2022-09-08T07:08:56.1549296Z       'content-encoding': 'gzip',
2022-09-08T07:08:56.1549847Z       'content-security-policy': "default-src 'none'",
2022-09-08T07:08:56.1550783Z       'content-type': 'application/json; charset=utf-8',
2022-09-08T07:08:56.1551324Z       date: 'Thu, 08 Sep 2022 07:08:56 GMT',
2022-09-08T07:08:56.1552018Z       'referrer-policy': 'origin-when-cross-origin, strict-origin-when-cross-origin',
2022-09-08T07:08:56.1552617Z       server: 'GitHub.com',
2022-09-08T07:08:56.1553253Z       'strict-transport-security': 'max-age=31536000; includeSubdomains; preload',
2022-09-08T07:08:56.1553806Z       'transfer-encoding': 'chunked',
2022-09-08T07:08:56.1554380Z       vary: 'Accept-Encoding, Accept, X-Requested-With',
2022-09-08T07:08:56.1554928Z       'x-content-type-options': 'nosniff',
2022-09-08T07:08:56.1555414Z       'x-frame-options': 'deny',
2022-09-08T07:08:56.1555953Z       'x-github-media-type': 'github.v3; format=json',
2022-09-08T07:08:56.1556556Z       'x-github-request-id': '0442:075D:11E2169:24B2089:63199508',
2022-09-08T07:08:56.1557061Z       'x-ratelimit-limit': '30',
2022-09-08T07:08:56.1557547Z       'x-ratelimit-remaining': '29',
2022-09-08T07:08:56.1558050Z       'x-ratelimit-reset': '1662620996',
2022-09-08T07:08:56.1558543Z       'x-ratelimit-resource': 'search',
2022-09-08T07:08:56.1559458Z       'x-ratelimit-used': '1',
2022-09-08T07:08:56.1560234Z       'x-xss-protection': '0'
2022-09-08T07:08:56.1560597Z     },
2022-09-08T07:08:56.1560829Z     data: {
2022-09-08T07:08:56.1561658Z       documentation_url: 'https://docs.github.com/en/free-pro-team@latest/rest/overview/resources-in-the-rest-api#secondary-rate-limits',
2022-09-08T07:08:56.1562747Z       message: 'You have exceeded a secondary rate limit. Please wait a few minutes before you try again.'
2022-09-08T07:08:56.1563217Z     }
2022-09-08T07:08:56.1563510Z   },
2022-09-08T07:08:56.1563811Z   request: {
2022-09-08T07:08:56.1564195Z     method: 'GET',
2022-09-08T07:08:56.1565935Z     url: 'https://api.github.com/search/issues?q=repo%3ATrendyol%2Fbaklava+type%3Apr+is%3Amerged+116919c5904430c79d03fb6a5318bedad01ff6c0+04b0023931a27511cd13154811be7d3cbe16f27f+2ad6dfbd6258faf9ae08358a3ad48b96dcd5c714+9fd294cf0ff8aac8cbfd3279f3ff5588420d00a2+75c8ec4eabc331039855982ef9aeca10170ebba4',
2022-09-08T07:08:56.1567082Z     headers: {
2022-09-08T07:08:56.1567664Z       accept: 'application/vnd.github.v3+json',
2022-09-08T07:08:56.1568374Z       'user-agent': 'octokit-rest.js/19.0.4 octokit-core.js/4.0.5 Node.js/16.17.0 (linux; x64)',
2022-09-08T07:08:56.1569265Z       authorization: 'token [REDACTED]'
2022-09-08T07:08:56.1569643Z     },
2022-09-08T07:08:56.1570086Z     request: { agent: undefined, hook: [Function: bound bound register] }
2022-09-08T07:08:56.1570485Z   },
2022-09-08T07:08:56.1570948Z   pluginName: '@semantic-release/github'
2022-09-08T07:08:56.1571329Z }
2022-09-08T07:08:56.1571586Z AggregateError: 
2022-09-08T07:08:56.1572056Z     HttpError: You have exceeded a secondary rate limit. Please wait a few minutes before you try again.
2022-09-08T07:08:56.1572861Z         at /home/runner/.npm/_npx/cdf31b77322f1d44/node_modules/@octokit/request/dist-node/index.js:88:21
2022-09-08T07:08:56.1573497Z         at processTicksAndRejections (node:internal/process/task_queues:96:5)
2022-09-08T07:08:56.1574356Z     at /home/runner/.npm/_npx/cdf31b77322f1d44/node_modules/semantic-release/lib/plugins/pipeline.js:54:11
2022-09-08T07:08:56.1575378Z     at async Object.pluginsConf.<computed> [as success] (/home/runner/.npm/_npx/cdf31b77322f1d44/node_modules/semantic-release/lib/plugins/index.js:80:11)
2022-09-08T07:08:56.1576279Z     at async run (/home/runner/.npm/_npx/cdf31b77322f1d44/node_modules/semantic-release/index.js:209:3)
2022-09-08T07:08:56.1577158Z     at async module.exports (/home/runner/.npm/_npx/cdf31b77322f1d44/node_modules/semantic-release/index.js:269:22)
2022-09-08T07:08:57.5144060Z     at async module.exports (/home/runner/.npm/_npx/cdf31b77322f1d44/node_modules/semantic-release/cli.js:55:5)
2022-09-08T07:08:57.5157455Z ##[error]Process completed with exit code 1.

I don't see any reason to hit a rate limit on our case. Any idea how to avoid this?

muratcorlu avatar Sep 08 '22 07:09 muratcorlu