When a task has a large number of prereqs and parallelLimit > 1,
each time a prereq finishes, it starts another prereq with a
recursive call, and this can overflow the nodejs stack.
The fix is to defer execution of the next prereq with setImmediate.
I had previously fixed this problem for some cases, but there
was a case that I missed.
This change fixes that case, and also adds a test that triggers
that case.
When a task has a large number of prereqs and parallelLimit > 1, each time a prereq finishes, it starts another prereq with a recursive call, and this can overflow the nodejs stack.
The fix is to defer execution of the next prereq with setImmediate.
I had previously fixed this problem for some cases, but there was a case that I missed.
This change fixes that case, and also adds a test that triggers that case.