#29182: SQLite 3.26 breaks database migration ForeignKey constraint, leaving
<table_name>__old in db schema
----------------------------------+------------------------------------
     Reporter:  ezaquarii         |                    Owner:  nobody
         Type:  Bug               |                   Status:  new
    Component:  Migrations        |                  Version:  2.1
     Severity:  Release blocker   |               Resolution:
     Keywords:  sqlite migration  |             Triage Stage:  Accepted
    Has patch:  0                 |      Needs documentation:  0
  Needs tests:  0                 |  Patch needs improvement:  0
Easy pickings:  0                 |                    UI/UX:  0
----------------------------------+------------------------------------

Comment (by Simon Charette):

 > We cannot safely alter a SQLite database inside a transaction from the
 looks of it...

 It has been working just fine on SQLite < 3.26 and the tests prove it.

 The current issue with 3.26 is that it changes the assumptions related to
 foreign key repointing on table rename when constraint checks are
 disabled. On SQLite < 3.26 renaming a table like we do in table remake
 because of unsupported `ALTER table` doesn't automatically repoint the
 foreign key constraints (e.g from `table_name` to `table_name__old`) but
 it does on SQLite 3.26.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/29182#comment:25>
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 django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/067.81204d1d71b788ce6fe55747046ba5bb%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to