Within lib/flok.js.sortMigrationsUp, efforts are made to resolve dependencies. However, if a dependency is not satisfiable, a call to this function invokes an infinite while loop.
Consider a migration with this set of dependencies
module.exports.dependencies = ['1',, '2'];
Assume '1' and '2' are valid migration ids. unresolvedDeps is filtered down to [undefined], but undefined is never identified as a valid migration id, resulting in an infinite loop.
In this situation, I would expect that the function calls back with an error detailing what dependencies cannot be met.
Within
lib/flok.js.sortMigrationsUp, efforts are made to resolve dependencies. However, if a dependency is not satisfiable, a call to this function invokes an infinite while loop.Consider a migration with this set of dependencies
Assume '1' and '2' are valid migration ids.
unresolvedDepsis filtered down to[undefined], butundefinedis never identified as a valid migration id, resulting in an infinite loop.In this situation, I would expect that the function calls back with an error detailing what dependencies cannot be met.