-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Result of async.timeout() only works the first time you call it. #1418
Comments
This may actually be by design, but if so it wasn't what I expected, and it wasn't indicated in the documentation from what I could see. Simple workaround is to instead simply wrap the function each time before you call it, i.e.:
|
Hi @acjohnso25, I believe you're right that this is bug. It should only give a |
I guess it's more correct to say that it works until the first timeout...then it always times out. For example, if you change
...then what you see is:
|
Allow functions wrapped in `timeout` to be called multiple times (fixes #1418)
Yeesh, I almost feel like we should do patch releases back to 2.0.0. |
Fixed in v2.4.1 |
What version of async are you using? 2.4.0
Which environment did the issue occur in (Node version/browser version) Node.js 4.7.0
What did you do? Please include a minimal reproducable case illustrating issue.
What did you expect to happen? Should only get timeout error the first time it's called.
What was the actual result? Timeout occurs every time it's called, even though the underlying function only takes too long the first time.
The text was updated successfully, but these errors were encountered: