-
Notifications
You must be signed in to change notification settings - Fork 95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Squash migrations #31
Comments
I will only squash dsmr_stats, reducing 16 migrations (files) to just a single one. It also renders all runPython migrations obsolete, as Django will run the old migrations for checkouts halfway migrated and the squashed ones for new checkouts. |
I will also drop any prints in legacy migration, as they are deployed everywhere by now. RunPython-migrations will be dropped completely in the squashed version, because they only fix existing data. |
Added a runpython for database init of |
I think I'm running into a migration bug in Django, but I'm not sure. It seems index operations for MySQL and PostgreSQL do not respect the operation order. When a squashed migration ends up having this:
Then the creation of the index is delayed after dropping the model, which is denied by the database. Only SQLite seems unaffected. |
Seems related to: I think the reason behind is that Fow now I will fix it manually by dropping |
Merged & deployed. |
Originally reported by: Dennis Siemensma (Bitbucket: dennissiemensma, GitHub: dennissiemensma)
https://docs.djangoproject.com/es/1.9/topics/migrations/#squashing-migrations
Can only be executed (remove old migrations) when every user has deployed all migrations squeezed.
The text was updated successfully, but these errors were encountered: