#25616: Add note regarding missing dependencies on LookupError for migrations
--------------------------------------+------------------------------------
     Reporter:  mcfletch              |                    Owner:  nip3o
         Type:  Cleanup/optimization  |                   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 nip3o):

 * needs_tests:  1 => 0


Comment:

 New patch inspired from previous patch, including test:
 https://github.com/django/django/pull/6699/

 However, I realize that I'm not sure when this actually happens in
 practice, which means that the new error message may actually be more
 misleading then the old one.
 * When trying to migrate model with a reference to an app which is not in
 `INSTALLED_APPS`, we will typically get a `SystemCheckError` before the
 migration even starts.
 * When the app we depend upon is in `INSTALLED_APPS`, but the app is not
 included in `dependencies`, we seems to get a `ValueError: Related model
 ... cannot be resolved`.
 * When the name of an app in `dependencies` in  the migration file does
 not exist, we get a NodeNotFoundError.

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

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.609e66b3acae19f8534cb1666b7d284b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to