#24038: Migrations won't add dependencies to existing migrations
----------------------------+----------------------------------------
     Reporter:  nitely      |      Owner:  nobody
         Type:  Bug         |     Status:  new
    Component:  Migrations  |    Version:  1.7
     Severity:  Normal      |   Keywords:  Migrations AUTH_USER_MODEL
 Triage Stage:  Unreviewed  |  Has patch:  0
Easy pickings:  0           |      UI/UX:  0
----------------------------+----------------------------------------
 I've this app that uses a custom user model. I've created initial
 migrations. Anyone interested in replacing/extending my
 [https://github.com/nitely/Spirit/blob/master/spirit/models/user.py custom
 user model] has to set `AUTH_USER_MODEL` to their own custom user model
 that inherits from my abstract user model.

 When running `./manage migrate` it fails with:

 {{{
 Running migrations:
   Applying spirit.0001_initial...Traceback (most recent call last):
   File "C:\Users\Admin\PycharmProjects\VEnv\Spirit-gh34\lib\site-
 packages\django\apps\registry.py", line 148, in get_app_config
     return self.app_configs[app_label]
 KeyError: 'myuserapp'
 }}}

 After adding `('myuserapp', '0001_initial'),` to `spirit.0001_initial`
 dependencies list, everything works as expected.

 To fix this, django should be able to add dependencies to existing
 migrations.

--
Ticket URL: <https://code.djangoproject.com/ticket/24038>
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/049.3a34fb5b8fa97908cdebc6233aa97444%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to