Opened 9 years ago

Closed 8 years ago

Last modified 8 years ago

#25044 closed Bug (fixed)

Renaming a ManyToManyField's through table creates a broken migration

Reported by: Ian Foote Owned by: Vytis Banaitis
Component: Migrations Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

I've created a minimal example demonstating the broken migration at https://github.com/Ian-Foote/django-bug-sandbox/pull/1.

Change History (13)

comment:1 by Ian Foote, 9 years ago

Component: UncategorizedMigrations
Type: UncategorizedBug

comment:2 by Tim Graham, 9 years ago

Triage Stage: UnreviewedAccepted

comment:3 by AndrewGrossman, 9 years ago

Owner: changed from nobody to AndrewGrossman
Status: newassigned

comment:4 by Sambhav Satija, 9 years ago

Owner: changed from AndrewGrossman to Sambhav Satija

I'd like to take a stab at it for a couple of days.

comment:5 by Sambhav Satija, 9 years ago

Owner: Sambhav Satija removed
Status: assignednew

Releasing the ticket since I haven't been able to find time to look at it.

comment:6 by Tim Graham, 8 years ago

Closed #26564 as a duplicate.

comment:7 by Vytis Banaitis, 8 years ago

Has patch: set
Owner: set to Vytis Banaitis
Status: newassigned

PR based on a fix in 107c9f5 for a similar problem.

comment:8 by Tim Graham, 8 years ago

Patch needs improvement: set

Comments for improvement on the PR.

comment:9 by Vytis Banaitis, 8 years ago

Patch needs improvement: unset

I have created a new PR, in which I've updated RenameModel operation to deal with M2M through.

comment:10 by Simon Charette, 8 years ago

Version: 1.8master

#22931 might also be solved by this change.

comment:11 by Simon Charette, 8 years ago

Triage Stage: AcceptedReady for checkin

comment:12 by Tim Graham <timograham@…>, 8 years ago

Resolution: fixed
Status: assignedclosed

In f1e408ff:

Fixed #25044 -- Fixed migrations for renaming ManyToManyField's through model.

comment:13 by Tim Graham <timograham@…>, 8 years ago

In b737c0f:

[1.10.x] Fixed #25044 -- Fixed migrations for renaming ManyToManyField's through model.

Backport of f1e408ff40d2c1753f92515c70a44634b4d47467 from master

Note: See TracTickets for help on using tickets.
Back to Top