#36165: Postgres schema editor throws away custom index deletion SQL
-------------------------------------+-------------------------------------
     Reporter:  Daniel Finch         |                    Owner:  Natalia
                                     |  Bidart
         Type:  Bug                  |                   Status:  assigned
    Component:  Database layer       |                  Version:  dev
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Natalia Bidart):

 * component:  CSRF => Database layer (models, ORM)
 * has_patch:  0 => 1
 * owner:  (none) => Natalia Bidart
 * stage:  Unreviewed => Accepted
 * status:  new => assigned
 * version:  5.1 => dev

Comment:

 Hello Daniel, thank you for your report. I have spent some time reviewing
 code and docs for `Index`. First of all,
 [https://docs.djangoproject.com/en/5.1/ref/models/indexes/ the docs] do
 not document the methods `create_sql` or `remove_sql`, so overriding these
 is not necessarily supported. But, after further investigation I found:
 * revno bd366ca2aeffa869b7dbc0b0aa01caea75e6dc31 added the support for the
 custom `sql` in create index
 * the rationale from Mariusz is still valid "''this may be helpful for
 3rd-party database backends that subclass django.db.backends.postgresql. I
 think it's worth adding''".

 Given the above, I'm accepting this ticket and I'm pushing a branch with
 fix and regression test for both methods.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/36165#comment:1>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/django-updates/01070194d6aa6270-965292e9-18ca-4294-89f3-ec05f7d57f1b-000000%40eu-central-1.amazonses.com.

Reply via email to