attempt
attempt copied to clipboard
Initial Delay does not seem to be respected
Running some tests, it seems as though setting initialDelay
does not affect the initial start time for the delay.
Setting delay
however will reduce the initial start delay.
@Banashek the code is fairly straight-forward for handling initial delay. See https://github.com/lifeomic/attempt/blob/master/src/index.ts#L191
The only case when initialDelay
is ignored is when you provide a calcualateDelay
function via the options. If calcualateDelay
is provided then the return value from the function will override all other default delay calculations.
Please provide examples of breaking test case (preferably in a pull request) if you can reproduce this problem.