migri/migration.py
async def _migrations_to_apply(
        self, migrations: List[Migration]
    ) -> List[Migration]:
        """Takes migration paths and uses migration file names to search for entries in
        'applied_migration' table
        """
        to_apply = []

        for migration in migrations:
            query = Query(
                f"SELECT id FROM {MIGRATION_TABLE_NAME} WHERE name = $migration_name",
                values={"migration_name": migration.name},
            )
            applied_migration = await self._connection.fetch_all(query)

            if not applied_migration:
                to_apply.append(migration)

        return to_apply
Takes migration paths and uses migration file names to search for entries in
        'applied_migration' table
        
Takes migration paths and uses migration file names to search for entries in
'applied_migration' table
Takes migration paths and uses migration file names to search for entries in ' applied_migration ' table
async def _migrations_to_apply(
        self, migrations: List[Migration]
    ) -> List[Migration]:
        to_apply = []
        for migration in migrations:
            query = Query(
                f"SELECT id FROM {MIGRATION_TABLE_NAME} WHERE name = $migration_name",
                values={"migration_name": migration.name},
            )
            applied_migration = await self._connection.fetch_all(query)
            if not applied_migration:
                to_apply.append(migration)
        return to_apply
async def _migrations_to_apply ( self , migrations : List [ Migration ] ) -> List [ Migration ] : to_apply = [ ] for migration in migrations : query = Query ( f"SELECT id FROM {MIGRATION_TABLE_NAME} WHERE name = $migration_name" , values = { "migration_name" : migration . name } , ) applied_migration = await self . _connection . fetch_all ( query ) if not applied_migration : to_apply . append ( migration ) return to_apply
Takes migration paths and uses migration file names to search for entries in
'applied_migration' table
Takes migration paths and uses migration file names to search for entries in ' applied_migration ' table
"""Takes migration paths and uses migration file names to search for entries in
        'applied_migration' table
        """
self
migrations
List[Migration]