code: def sorted_migrations(self):
          
          if not self._sorted_migrations:
              self._sorted_migrations = sorted(
                  self.migration_registry.items(),
                  # sort on the key... the migration number
                  key=lambda migration_tuple: migration_tuple[0])
  
          return self._sorted_migrations
docs: Sort migrations if necessary and store in self._sorted_migrations