CommandError: Can’t locate revision identified by ‘…’ when migrating using Flask-Migrate

you delete the migration directory but the version has been saved in the database, so you have to delete the version info in the dabase,
run

delete from alembic_version;

in mysql shell.

As suggested by @mirekphd, If this is a developing environment or a single app for test, just delete it, Else BACKUP the data in the table.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)