9 comments

[ 2.8 ms ] story [ 72.0 ms ] thread
This looks really cool, awesome job! We desperately need something like this at my day job, but unfortunately we use MySQL and Django.
While it hasn't been updated in a while, fundamentally https://github.com/pombredanne/django-zerodowntime would be a base for building similar check logic in a DB agnostic way on Django. It has some of the most important checks in place, but could obviously do with adding more sophisticated checks.

For Django users using PostgreSQL you can use https://github.com/antonioIrizar/django-check-migration-wtf or https://github.com/yandex/zero-downtime-migrations or https://github.com/tbicr/django-pg-zero-downtime-migrations to provide similar functionality to the library this post links to, depending on your exact use case of course.

This is cool. We use strong_migrations but I’ll check this out. I love the idea of an enforced pattern for background data migrations.

While I’m here a shameless plug for a gem we built that we’ve found incredibly helpful for safer migrations - https://github.com/TandaHQ/migration_signature

It adds a CI check to guarantee the migrations you tested in development are actually the migrations that run in production.

Thanks for mentioning. Nice logo! I have seen that and borrowed verbose sql logging. Nice gem, I see the differences.

My gem:

1. has more checks 2. has more migration helpers (renaming tables/columns, changing columns types, backfilling etc) 3. more flexible in terms of configuration 4. has background data migrations 5. does not disables wrapping migrations in a transaction, which can be inconvenient and dangerous