Changes between Initial Version and Version 1 of Ticket #30189
- Timestamp:
- Feb 16, 2019, 10:52:37 AM (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #30189 – Description
initial v1 1 1 The migration executor only adds the outer `BEGIN`/`COMMIT` [https://github.com/django/django/blob/edec11ce86a1a0d9e4c5a2a0df6acaf655041c24/django/db/migrations/executor.py#L243-L247 if the migration is atomic] and [https://github.com/django/django/blob/edec11ce86a1a0d9e4c5a2a0df6acaf655041c24/django/db/backends/base/schema.py#L97 the schema editor can rollback DDL] but the current `sqlmigrate` logic only takes `migration.atomic` into consideration. 2 2 3 The issue c hangebe addressed by3 The issue can be addressed by 4 4 5 5 1. Changing `sqlmigrate` [https://github.com/django/django/blob/edec11ce86a1a0d9e4c5a2a0df6acaf655041c24/django/core/management/commands/sqlmigrate.py#L59 assignment] of `self.output_transaction` to consider `connection.features.can_rollback_ddl` as well.