Database migrations

Migrations are forward-only and operate on PostgreSQL canonical metadata. Run make migration-check to render the full upgrade path without changing a database. Integration tests also apply the migration to a temporary database and compare it with SQLAlchemy metadata.