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

fix: default maxDelay to max 32-bit signed integer #45

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mhassan1
Copy link

@mhassan1 mhassan1 commented May 9, 2023

This PR updates the default maxDelay to the maximum 32-bit signed integer (2 ** 31 - 1).

The default maxDelay of Infinity doesn't make sense, since setTimeout doesn't accept anything larger than the maximum 32-bit signed integer; when that value is exceeded, setTimeout treats it as 1, which can cause runaway retries.

Resolves #44.

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.

TimeoutOverflowWarning after many retries
1 participant