#23100: Applying migrations fails when adding a ForeignKey to swappable user
model
after initial migration
----------------------------+--------------------------------------
Reporter: mattias | Owner: nobody
Type: Bug | Status: new
Component: Migrations | Version: 1.7-rc-1
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 mattias):
* needs_better_patch: => 0
* needs_tests: => 0
* needs_docs: => 0
Comment:
Sorry, I missed a step in the reproduction instructions. They are:
1. Create a swappable user model, add it to settings.py, create and run
migrations.
2. Create a new model in a new app. Do not give it a reference to the user
model.
3. Run makemigrations and migrate. Both work.
4. Add a ForeignKey from the new model to the custom user model.
5. Run makemigrations. This works.
6. Run migrate. This fails.
--
Ticket URL: <https://code.djangoproject.com/ticket/23100#comment:1>
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/065.c402ac95716d8d8944a5a0366b18fc4b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.