sqlmigrate wraps it's outpout in BEGIN/COMMIT even if the database doesn't support transactional DDL
|Patch needs improvement:
Description (last modified by )
The migration executor only adds the outer
COMMIT if the migration is atomic and the schema editor can rollback DDL but the current
sqlmigrate logic only takes
migration.atomic into consideration.
The issue can be addressed by
- Adding a test in
tests/migrations/test_commands.pybased on an existing test for non-atomic migrations that mocks
Falseinstead of overdidding
MIGRATION_MODULESto point to a non-atomic migration.
I marked the ticket as easy picking because I included the above guidelines but feel free to uncheck it if you deem it inappropriate.
Change History (7)
comment:6 by , 5 years ago