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

(@actions/attest) retry request on failure to save attestation #1725

Merged
merged 1 commit into from Apr 25, 2024

Conversation

bdehamer
Copy link
Contributor

@bdehamer bdehamer commented Apr 24, 2024

Updates the attestations API client to be more resilient to intermittent errors.

Enables the @octokit/plugin-retry plugin for the Octokit client and configures a (default) retry count of 3. Any attempt to persist the generated attestation which results in a 5XX error will be retried up to 5 times (with exponential backoff).

@bdehamer bdehamer requested a review from a team as a code owner April 24, 2024 18:41
Comment on lines +55 to +58
"overrides": {
"@octokit/plugin-retry": {
"@octokit/core": "^5.2.0"
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The @octokit/plugin-retry package has a very loose peer dependency on @octokit/core, however we need to pin it to the same version which is used by @actions/github to avoid issues with type inconsistencies.

Signed-off-by: Brian DeHamer <bdehamer@github.com>
@bdehamer bdehamer force-pushed the bdehamer/attest-retry-persist branch from 8cf47ad to 0e8fe8a Compare April 24, 2024 22:07
@bdehamer bdehamer requested a review from trevrosen April 24, 2024 22:27
@bdehamer bdehamer merged commit 81a73ab into main Apr 25, 2024
14 checks passed
@bdehamer bdehamer deleted the bdehamer/attest-retry-persist branch April 25, 2024 02:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants