Opened 19 months ago

Last modified 19 months ago

#34336 closed Bug

Reverting a migration with `replaces = [...]` set does not revert it — at Version 1

Reported by: Thomas C Owned by: nobody
Component: Migrations Version: 3.2
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by Thomas C)

I have four migrations in an app. In migration 4, I have replaces = [("my_app", "0002_foo")].

When I migrate back from the state where all migration are applied to the first migration, it says that the migration 4 has been reverted.

However, that migration is still marked as passed in the django_migrations table and when I try to migrate again to the state 4 it fails saying that migration 4 was already applied.

Is rollbacking a migration where replaces is set supported? How is that supposed to behave, regarding the migration and the one it replaces?

Change History (1)

comment:1 by Thomas C, 19 months ago

Description: modified (diff)
Note: See TracTickets for help on using tickets.
Back to Top