p-retry v7.0.0

v7.0.0
Added 1
  • Add makeRetriable method
Changed 2
  • onFailedAttempt and shouldRetry now receive a context object instead of a decorated error, with the error accessible as context.error
  • Rewrite the package to not depend on the retry package
Removed 2
  • Require Node.js 20 or later
  • Remove the forever option, use {retries: Infinity} instead for infinite retries

From p-retry

Breaking
  • Require Node.js 20 3bdb53a
  • onFailedAttempt and shouldRetry now receive a context object instead of a decorated error bff36bb
    • You must now must access the error as object.error instead of object.
    • The use of .attemptNumber and .retriesLeft did not change.
  • Remove the forever option (#79) 6a89827
    • Many use-cases can use {retries: Infinity} instead for infinite retries.
Improvements
  • Rewrite the package to not depend on the retry package (#79) 6a89827
    • This is a full rewrite, so test carefully.
  • Add makeRetriable method 1a81c1e

https://github.com/sindresorhus/p-retry/compare/v6.2.1...v7.0.0

View original

Upgraded? How did it go?

Discussion