near-api-js icon indicating copy to clipboard operation
near-api-js copied to clipboard

fix: retry on HTTP 408 error

Open danielwpz opened this issue 2 years ago • 2 comments

Motivation

When testing contracts with near-workspace, HTTP 408 error frequently crashes the tests. However this could be resolved by just retrying the request.

Description

Retry on http 408 error.

Checklist

  • [ ] Read the contributing guidelines
  • [ ] Commit messages follow the conventional commits spec
  • [ ] Performed a self-review of the PR
  • [ ] Added automated tests
  • [ ] Manually tested the change

danielwpz avatar Sep 20 '22 08:09 danielwpz

⚠️ No Changeset found

Latest commit: 3704ca2619a9e5852f012067c97c36fe31ddd799

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

changeset-bot[bot] avatar Sep 21 '22 08:09 changeset-bot[bot]

@volovyks mind taking a look at this tiny PR?

danielwpz avatar Sep 26 '22 03:09 danielwpz

the idea of retrying on 408 HTTP error looks reasonable to me, so I've made this code work without merge conflicts in https://github.com/near/near-api-js/pull/1205

I'd suggest closing this one so we don't leave it out of date

denbite avatar Nov 21 '23 17:11 denbite