Closed GuerrettaG closed 10 months ago
@GuerrettaG thanks for your contribution. What version of Django supports can_rollback_ddl ? And have you tested this ?
It is supported at least from Django > 2.2.0. I have tested by manually running migrations and reverting them on an empty DB2 schema.
This will set the default behavior when running a migration. See: https://github.com/django/django/blob/d22ba0763086f71fb6df8502162ea63944d166b1/django/db/migrations/migration.py#L123-L134 and https://github.com/django/django/blob/d22ba0763086f71fb6df8502162ea63944d166b1/django/db/backends/postgresql/features.py#L30C2-L30C2 For the example in the default postgres driver.