[Django] #27461: makemigrations router.allow_migrate() calls for consistency checks use incorrect (app_label, model) pairs

18 views
Skip to first unread message

Django

unread,
Nov 8, 2016, 1:05:07 PM11/8/16
to django-...@googlegroups.com
#27461: makemigrations router.allow_migrate() calls for consistency checks use
incorrect (app_label, model) pairs
-------------------------------------+-------------------------------------
Reporter: Joseph | Owner: nobody
Kahn |
Type: Bug | Status: new
Component: Core | Version: 1.10
(Management commands) |
Severity: Release | Keywords:
blocker |
Triage Stage: Accepted | Has patch: 1
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
As reported in ticket:27200#comment:14, I `makemigrations` incorrectly
calls `allow_migrate()` for each app with all the models in the project
rather than for each app with the app's models. It broke the router I use
because it was passing invalid combinations for shards since not all
shards have the same models.

[​https://github.com/django/django/pull/7530 PR]

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

Django

unread,
Nov 9, 2016, 7:36:58 AM11/9/16
to django-...@googlegroups.com
#27461: makemigrations router.allow_migrate() calls for consistency checks use
incorrect (app_label, model) pairs
-------------------------------------+-------------------------------------
Reporter: Joseph Kahn | Owner: nobody
Type: Bug | Status: new
Component: Core (Management | Version: 1.10
commands) |
Severity: Release blocker | 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 Tim Graham):

* stage: Accepted => Ready for checkin


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

Django

unread,
Nov 9, 2016, 10:27:39 AM11/9/16
to django-...@googlegroups.com
#27461: makemigrations router.allow_migrate() calls for consistency checks use
incorrect (app_label, model) pairs
-------------------------------------+-------------------------------------
Reporter: Joseph Kahn | Owner: nobody
Type: Bug | Status: closed

Component: Core (Management | Version: 1.10
commands) |
Severity: Release blocker | 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: new => closed
* resolution: => fixed


Comment:

In [changeset:"373c6c409c310cb61e1e9c9aff4adba379ffd0b4" 373c6c4]:
{{{
#!CommitTicketReference repository=""
revision="373c6c409c310cb61e1e9c9aff4adba379ffd0b4"
Fixed #27461 -- Fixed incorrect allow_migrate() arguments in
makemigrations.
}}}

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

Django

unread,
Nov 9, 2016, 10:33:17 AM11/9/16
to django-...@googlegroups.com
#27461: makemigrations router.allow_migrate() calls for consistency checks use
incorrect (app_label, model) pairs
-------------------------------------+-------------------------------------
Reporter: Joseph Kahn | Owner: nobody
Type: Bug | Status: closed
Component: Core (Management | Version: 1.10
commands) |
Severity: Release blocker | 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:"7fd379719a1f5ee059aeee88243af172719e5e35" 7fd3797]:
{{{
#!CommitTicketReference repository=""
revision="7fd379719a1f5ee059aeee88243af172719e5e35"
[1.10.x] Fixed #27461 -- Fixed incorrect allow_migrate() arguments in
makemigrations.

Backport of 373c6c409c310cb61e1e9c9aff4adba379ffd0b4 from master
}}}

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

Reply all
Reply to author
Forward
0 new messages