Skip to content

Commit 66ddf90

Browse files
committed
output retryafter for secondary rate limit
1 parent fd3e742 commit 66ddf90

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

dist/index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1498,8 +1498,9 @@ exports.throttleOptions = {
14981498
return true;
14991499
}
15001500
},
1501-
onSecondaryRateLimit: (_, options) => {
1501+
onSecondaryRateLimit: (retryAfter, options) => {
15021502
core.warning(`Hit secondary rate limit for request ${options.method} ${options.url}`);
1503+
core.warning(`Requests may be retried after ${retryAfter} seconds.`);
15031504
}
15041505
};
15051506
const proxyFetch = (proxyUrl) => (url, opts) => {

src/octokit-client.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,11 @@ export const throttleOptions = {
2525
return true
2626
}
2727
},
28-
onSecondaryRateLimit: (_, options) => {
28+
onSecondaryRateLimit: (retryAfter, options) => {
2929
core.warning(
3030
`Hit secondary rate limit for request ${options.method} ${options.url}`
3131
)
32+
core.warning(`Requests may be retried after ${retryAfter} seconds.`)
3233
}
3334
}
3435

0 commit comments

Comments
 (0)