{{{
0001_sq_0002
/ \
App A: 0001 ---> 0002
|
App B: 0001
}}}
When only A.0001 and B.0002 are applied
I think
[https://github.com/django/django/blob/main/django/db/migrations/loader.py#L320-L326
fix] applied in #27004 should check if any of migrations replaced are
already applied, not if all of them. When any of them is applied, we are
already on a separate path of applying migration and squash migration will
only be marked as applied, so it should be fine to change it from all to
any.
--
Ticket URL: <https://code.djangoproject.com/ticket/33734>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
Comment (by Mariusz Felisiak):
Thanks for the report. Can you provide a sample project? Can you reproduce
`InconsistentMigrationHistory` in the Django 4.0, 4.1a1, and the current
`main` branch? (we made some improvements in this area.)
--
Ticket URL: <https://code.djangoproject.com/ticket/33734#comment:1>
* status: new => closed
* resolution: => needsinfo
Comment:
I cannot reproduce any `InconsistentMigrationHistory` when only `A.0001`
and `B.0001` are applied (`B.0002` from the ticket description doesn't
exist.)
--
Ticket URL: <https://code.djangoproject.com/ticket/33734#comment:2>