It turns out it's already using lexicographical ordering, so the sorting logic based on name is unecessary. The issue was that magma was generating names using arithmetic ordering (e.g. "module8", "module9", "module10") which meant that once we hit module10 and beyond, they would move in front of the previous modules.
It turns out it's already using lexicographical ordering, so the sorting logic based on name is unecessary. The issue was that magma was generating names using arithmetic ordering (e.g. "module8", "module9", "module10") which meant that once we hit module10 and beyond, they would move in front of the previous modules.