Conversation
size-limit report 📦
|
|
Thanks @red-game-dev ! I'm going to merge soon. I'm going to prioritize this as we fix a small typings bug in the imports after 4.0.0, so probably 4.0.1 |
Perfect. Glad to see the package is improving. Hopefully people doesnt judge it by number of downloads, but actually try it, since at this point this package is super optimized and it is simple to use. Furthermore I may not be able to conduct reviews or contributing anymore soon as seems companies are starting not to be in favour of this for people to contribute or review in open source or even having side projects. Perhaps in the future I'll be able the help again 🙏 Cheers for making this package an amazing one 🚀 |
This pull request introduces enhancements to the retry logic for handling rate-limiting scenarios and updates the
package.jsonconfiguration. The key changes include improving the handling of HTTP headers for calculating retry delays, adding support for additional rate-limiting headers, and updating the library's size limits and type definitions.Improvements to Retry Logic:
getMsFromHttpDateto parse HTTP-date strings into milliseconds, ensuring proper handling ofRetry-Afterheaders. (src/retry-handler.ts, src/retry-handler.tsR6-R14)getRetryAfterMsfunction to handle additional rate-limiting headers such asratelimit-reset-afterandratelimit-reset-atfor more robust retry delay calculations. (src/retry-handler.ts, src/retry-handler.tsL20-R74)withRetryfunction to handle HTTP 503 (Service Unavailable) errors in addition to HTTP 429 (Too Many Requests) for rate-limiting scenarios. (src/retry-handler.ts, src/retry-handler.tsL142-R178)Updates to
package.json:package.json, [1] [2]package.json, package.jsonL72-R82)