-
Notifications
You must be signed in to change notification settings - Fork 4
add input delay option #169
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -18,13 +18,17 @@ export default class Input { | |||||
| readonly ifNotArchivedWithin = this.getInput('ifNotArchivedWithin', { | ||||||
| trimWhitespace: true, | ||||||
| }); | ||||||
| readonly delayBetweenRequests; | ||||||
|
||||||
| readonly delayBetweenRequests; | |
| readonly delayBetweenRequests: number | null; |
Copilot
AI
Apr 21, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This adds a new GitHub Action input, but action.yml currently does not declare delayBetweenRequests. Undeclared inputs are treated as unexpected by the runner and typically won’t be passed through, so this option may be unusable in real workflows until it’s added to the action metadata.
This issue also appears on line 29 of the same file.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -26,6 +26,9 @@ export default async function run(): Promise<void> { | |
| log.error(`Archive process failed for ${url}: ${err.message}`); | ||
| failures.push({ url, error: err }); | ||
| } | ||
| if (input.delayBetweenRequests) { | ||
| await Promise.delay(input.delayBetweenRequests); | ||
| } | ||
|
Comment on lines
+29
to
+31
|
||
| } | ||
|
|
||
| writeOutputs(results); | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Docs say “wait between web requests”, but the implementation delays only between top-level URL captures (and
WayBack.saveitself performs multiple requests/polls). Consider clarifying wording to avoid implying every internal request is delayed.This issue also appears on line 80 of the same file.