This behavior is bad if no (or only unmanaged) models reside in these
databases. In my case I have quite a lot of databases defined in
`settings.DATABASES` to be able to connect to them in a unified way. I
only do raw SQL in there, so Django should not mess with these databases
(or worse, introduce schema changes in third-party databases, like Django
1.10 does).
This is somewhat related to Bug #27054, although the fix provided there
does not solve the issue. This regression is introduced by
02ae5fd31a56ffb42feadb49c1f3870ba0a24869.
--
Ticket URL: <https://code.djangoproject.com/ticket/27110>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* status: new => assigned
* severity: Normal => Release blocker
* needs_better_patch: => 0
* component: Uncategorized => Migrations
* needs_tests: => 0
* owner: nobody => timgraham
* needs_docs: => 0
* type: Uncategorized => Bug
* stage: Unreviewed => Accepted
--
Ticket URL: <https://code.djangoproject.com/ticket/27110#comment:1>
* has_patch: 0 => 1
Comment:
[https://github.com/django/django/pull/7142 PR]
--
Ticket URL: <https://code.djangoproject.com/ticket/27110#comment:2>
Comment (by timgraham):
An alternate proposal about consulting database routers is under
discussion in #27142. It would be nice to have some confirmation that it
solves your use case.
--
Ticket URL: <https://code.djangoproject.com/ticket/27110#comment:3>
Comment (by timgraham):
There's a [https://github.com/django/django/pull/7194 new PR] which uses
the database routers idea.
--
Ticket URL: <https://code.djangoproject.com/ticket/27110#comment:4>
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"098c07a03286b5ed133102733e67a83061647ea0" 098c07a]:
{{{
#!CommitTicketReference repository=""
revision="098c07a03286b5ed133102733e67a83061647ea0"
Fixed #27142, #27110 -- Made makemigrations consistency checks respect
database routers.
Partially reverted refs #27054 except for one of the tests as this
solution supersedes that one.
Thanks Shai Berger for the review.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/27110#comment:5>
Comment (by Tim Graham <timograham@…>):
In [changeset:"3e913d214133ca92329ed95d55bd881e42d487ef" 3e913d2]:
{{{
#!CommitTicketReference repository=""
revision="3e913d214133ca92329ed95d55bd881e42d487ef"
[1.10.x] Fixed #27142, #27110 -- Made makemigrations consistency checks
respect database routers.
Partially reverted refs #27054 except for one of the tests as this
solution supersedes that one.
Thanks Shai Berger for the review.
Backport of 098c07a03286b5ed133102733e67a83061647ea0 from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/27110#comment:6>
Comment (by Tim Graham <timograham@…>):
In [changeset:"c93ac9cf42bff259ab71b70a89b693b9c38e4666" c93ac9cf]:
{{{
#!CommitTicketReference repository=""
revision="c93ac9cf42bff259ab71b70a89b693b9c38e4666"
Refs #25850, #27142, #27110 -- Documented migration history consistency
checks.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/27110#comment:7>
Comment (by Tim Graham <timograham@…>):
In [changeset:"57f7d8968d8443352ce331ad9dd6f433a15d0d93" 57f7d896]:
{{{
#!CommitTicketReference repository=""
revision="57f7d8968d8443352ce331ad9dd6f433a15d0d93"
[1.10.x] Refs #25850, #27142, #27110 -- Documented migration history
consistency checks.
Backport of c93ac9cf42bff259ab71b70a89b693b9c38e4666 from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/27110#comment:8>