def migrate():
    ' apply yoyo migrations '
    logger.info('Migrating to the latest schema')
    log.getLogger('yoyo').setLevel(log.DEBUG)
    backend = get_backend(('sqlite:///' + DB_PATH))
    migrations = read_migrations('./migrations')
    with backend.lock():
        backend.apply_migrations(backend.to_apply(migrations))
apply yoyo migrations
def migrate():
    '  '
    logger.info('Migrating to the latest schema')
    log.getLogger('yoyo').setLevel(log.DEBUG)
    backend = get_backend(('sqlite:///' + DB_PATH))
    migrations = read_migrations('./migrations')
    with backend.lock():
        backend.apply_migrations(backend.to_apply(migrations))