Saturday 11:30 a.m.–noon

Designing Django's Migrations

Andrew Godwin

Audience level:
Intermediate
Category:
Web Frameworks

Description

Django finally has built-in migrations, and they're a long way from the designs of South or django-evolution. Learn the key design decisions we made, ideas we discarded, and the unique treatment we have to give each of our four official database backends.

Abstract

It's been ten years in the making, but Django finally has built-in migrations. Inspired by South, django-evolution, Alembic, Rails and more, they're a brand new design with some unique design decisions and some exciting possibilities. Learn the key design decisions we made, ideas we discarded, and the unique treatment we have to give each of our four official database backends, as well as the challenges we faced in creating a new migration file format, how to do dependency resolution efficiently, and how we managed to make such a large change in a backwards-compatible way.