Expand description
Dependency graph resolution for native migrations.
Pure logic — no runtime, no I/O. Input is a list of migration names and
their dependency edges; output is a topologically-sorted application order
or a CycleError naming the involved migrations.
Structs§
Functions§
- topological_
sort - Sort
migrationsin topological order givenedges(migration → depends_on). - would_
create_ cycle - Check whether adding edge
from → towould create a cycle in the existing graph. Returns the cycle path if detected.