You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
AbortSignal.timeout throws RangeError with any decimal number input #58592
The bug is easy to reproduce using the timeout function with a decimal.
AbortSignal.timeout(1.1)
How often does it reproduce? Is there a required condition?
It always produces the same error.
What is the expected behavior? Why is that the expected behavior?
I'd expect it to work with all numbers, including decimal numbers, within the range of 0 and Number.MAX_SAFE_INTEGER. Browsers and other JS runtimes all seem to allow decimals. There is no mention of this special behavior in the NodeJS docs.
What do you see instead?
Uncaught:
RangeError [ERR_OUT_OF_RANGE]: The value of "delay" is out of range. It must be an integer. Received 1.1
at AbortSignal.timeout (node:internal/abort_controller:239:5) {
code: 'ERR_OUT_OF_RANGE'
}
This issue has been marked as stale due to 210 days of inactivity.
It will be automatically closed in 30 days if no further activity occurs. If this is still relevant, please leave a comment or update it to keep it open.
This issue has been marked as stale due to 90 days of inactivity.
It will be automatically closed in 30 days if no further activity occurs. If this is still relevant, please leave a comment or update it to keep it open.
This issue has been automatically closed after 30 days of inactivity following its stale status (no activity for a total of 120 days).
If this is still relevant, feel free to reopen it or leave a comment with additional details so we can continue the discussion.
Activity
Renegade334 commentedon Jun 5, 2025
cprass commentedon Jun 6, 2025
The spec defines how IDL types map to JavaScript https://webidl.spec.whatwg.org/#js-unsigned-long-long. Doesn't
[EnforceRange] unsigned long longallow any JS number and coerces the value?bakkot commentedon Jun 6, 2025
[EnforceRange]saysThe attribute is only about the upper and lower bounds, not about non-integer inputs. The example in that section has an input of
-0.9not throwing.BrodaNoel commentedon Jun 11, 2025
For some reason, I sudently have this issue as well.
github-actions commentedon Apr 19, 2026
This issue has been marked as stale due to 210 days of inactivity.
It will be automatically closed in 30 days if no further activity occurs. If this is still relevant, please leave a comment or update it to keep it open.
github-actions commentedon Jul 20, 2026
This issue has been marked as stale due to 90 days of inactivity.
It will be automatically closed in 30 days if no further activity occurs. If this is still relevant, please leave a comment or update it to keep it open.
github-actions commentedon Aug 20, 2026
This issue has been automatically closed after 30 days of inactivity following its stale status (no activity for a total of 120 days).
If this is still relevant, feel free to reopen it or leave a comment with additional details so we can continue the discussion.