#30910: Add system check warning on duplicate check constraints.
------------------------------------------------+------------------------
               Reporter:  Jon Dufresne          |          Owner:  nobody
                   Type:  New feature           |         Status:  new
              Component:  Core (System checks)  |        Version:  master
               Severity:  Normal                |       Keywords:
           Triage Stage:  Unreviewed            |      Has patch:  0
    Needs documentation:  0                     |    Needs tests:  0
Patch needs improvement:  0                     |  Easy pickings:  0
                  UI/UX:  0                     |
------------------------------------------------+------------------------
 Recently, due to an oversight when copying & pasting code, I created a
 duplicate `CheckConstraint`. I had intended to modify the `check` argument
 after pasting, but I made a mistake. In this specific instance, the
 mistake was caught and fixed during a routine code review, but it made me
 think this is something that could be warned against by Django so it is
 caught early.

 While a duplicate check constraint is legal SQL, it normally points to an
 error on the part of the developer. We can issue a `Warning` in such a
 case.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/30910>
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 on the web visit 
https://groups.google.com/d/msgid/django-updates/052.3bdc94fe2612e321e841f047895e37fe%40djangoproject.com.

Reply via email to