django migration No migrations to apply

今天遇到一个问题:

更新manage.py后执行,仍然出现

yangrui@ubuntu:~/Django/day3$ ./manage.py migrate
Operations to perform:
Apply all migrations: admin, auth, contenttypes, index, sessions
Running migrations:
No migrations to apply.

试了好多方法,最后解决

在mysql中执行

DELETE FROM django_migrations WHERE app='your-app-name';

猜你喜欢

转载自www.cnblogs.com/sike8/p/11394407.html