[Django] #25044: Renaming a ManyToManyField's through table creates a broken migration

60 views
Skip to first unread message

Django

unread,
Jul 1, 2015, 10:50:21 AM7/1/15
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
-------------------------------+--------------------
Reporter: Ian-Foote | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 1.8
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------
I've created a minimal example demonstating the broken migration at
https://github.com/Ian-Foote/django-bug-sandbox/pull/1.

--
Ticket URL: <https://code.djangoproject.com/ticket/25044>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Jul 2, 2015, 11:27:54 AM7/2/15
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+--------------------------------------
Reporter: Ian-Foote | Owner: nobody
Type: Bug | Status: new
Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+--------------------------------------
Changes (by Ian-Foote):

* needs_better_patch: => 0
* type: Uncategorized => Bug
* component: Uncategorized => Migrations
* needs_tests: => 0
* needs_docs: => 0


--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:1>

Django

unread,
Jul 2, 2015, 11:48:01 AM7/2/15
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+------------------------------------
Reporter: Ian-Foote | Owner: nobody

Type: Bug | Status: new
Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted

Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+------------------------------------
Changes (by timgraham):

* stage: Unreviewed => Accepted


--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:2>

Django

unread,
Jul 5, 2015, 9:38:43 PM7/5/15
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+------------------------------------------
Reporter: Ian-Foote | Owner: AndrewGrossman
Type: Bug | Status: assigned

Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+------------------------------------------
Changes (by AndrewGrossman):

* status: new => assigned
* owner: nobody => AndrewGrossman


--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:3>

Django

unread,
Aug 11, 2015, 9:15:35 PM8/11/15
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+-------------------------------------
Reporter: Ian-Foote | Owner: darkryder

Type: Bug | Status: assigned
Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+-------------------------------------
Changes (by darkryder):

* owner: AndrewGrossman => darkryder


Comment:

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

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:4>

Django

unread,
Sep 2, 2015, 9:32:53 PM9/2/15
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+------------------------------------
Reporter: Ian-Foote | Owner:
Type: Bug | Status: new

Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+------------------------------------
Changes (by darkryder):

* status: assigned => new
* owner: darkryder =>


Comment:

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

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:5>

Django

unread,
May 6, 2016, 8:09:37 AM5/6/16
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+------------------------------------
Reporter: Ian-Foote | Owner:
Type: Bug | Status: new
Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+------------------------------------

Comment (by timgraham):

Closed #26564 as a duplicate.

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:6>

Django

unread,
May 10, 2016, 5:46:05 PM5/10/16
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+------------------------------------
Reporter: Ian-Foote | Owner: vytisb
Type: Bug | Status: assigned

Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+------------------------------------
Changes (by vytisb):

* owner: => vytisb


* status: new => assigned

* has_patch: 0 => 1


Comment:

[https://github.com/django/django/pull/6584 PR] based on a fix in
[changeset:"107c9f545346149b03354678f53a177709edaced" 107c9f5] for a
similar problem.

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:7>

Django

unread,
May 13, 2016, 12:46:16 PM5/13/16
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+------------------------------------
Reporter: Ian-Foote | Owner: vytisb
Type: Bug | Status: assigned
Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1

Easy pickings: 0 | UI/UX: 0
----------------------------+------------------------------------
Changes (by timgraham):

* needs_better_patch: 0 => 1


Comment:

Comments for improvement on the PR.

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:8>

Django

unread,
May 21, 2016, 10:10:41 AM5/21/16
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+------------------------------------
Reporter: Ian-Foote | Owner: vytisb
Type: Bug | Status: assigned
Component: Migrations | Version: 1.8
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+------------------------------------
Changes (by vytisb):

* needs_better_patch: 1 => 0


Comment:

I have created a new [https://github.com/django/django/pull/6636 PR], in
which I've updated `RenameModel` operation to deal with M2M `through`.

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:9>

Django

unread,
May 25, 2016, 2:51:24 AM5/25/16
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+------------------------------------
Reporter: Ian-Foote | Owner: vytisb
Type: Bug | Status: assigned
Component: Migrations | Version: master

Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+------------------------------------
Changes (by charettes):

* version: 1.8 => master


Comment:

#22931 might also be solved by this change.

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:10>

Django

unread,
May 27, 2016, 9:13:53 PM5/27/16
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+---------------------------------------------

Reporter: Ian-Foote | Owner: vytisb
Type: Bug | Status: assigned
Component: Migrations | Version: master
Severity: Normal | Resolution:
Keywords: | Triage Stage: Ready for checkin

Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+---------------------------------------------
Changes (by charettes):

* stage: Accepted => Ready for checkin


--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:11>

Django

unread,
May 30, 2016, 10:18:14 AM5/30/16
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+---------------------------------------------
Reporter: Ian-Foote | Owner: vytisb
Type: Bug | Status: closed
Component: Migrations | Version: master
Severity: Normal | Resolution: fixed

Keywords: | Triage Stage: Ready for checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+---------------------------------------------
Changes (by Tim Graham <timograham@…>):

* status: assigned => closed
* resolution: => fixed


Comment:

In [changeset:"f1e408ff40d2c1753f92515c70a44634b4d47467" f1e408ff]:
{{{
#!CommitTicketReference repository=""
revision="f1e408ff40d2c1753f92515c70a44634b4d47467"
Fixed #25044 -- Fixed migrations for renaming ManyToManyField's through
model.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:12>

Django

unread,
May 30, 2016, 10:40:39 AM5/30/16
to django-...@googlegroups.com
#25044: Renaming a ManyToManyField's through table creates a broken migration
----------------------------+---------------------------------------------
Reporter: Ian-Foote | Owner: vytisb
Type: Bug | Status: closed
Component: Migrations | Version: master
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Ready for checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
----------------------------+---------------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"b737c0f5db8fe8499d39c39d2442eaee595ca0fd" b737c0f]:
{{{
#!CommitTicketReference repository=""
revision="b737c0f5db8fe8499d39c39d2442eaee595ca0fd"
[1.10.x] Fixed #25044 -- Fixed migrations for renaming ManyToManyField's
through model.

Backport of f1e408ff40d2c1753f92515c70a44634b4d47467 from master
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/25044#comment:13>

Reply all
Reply to author
Forward
0 new messages