I have two applications (ook
and eek
say) and I want to use a foreign key to a model in ook
from a model in eek
. Both are
In my case, It was the cache and previous migrations that resulted in this error. I removed __pycache__
and migrations folder and then re-run the migrations command and it worked.
Remember, when you'll do python manage.py makemigrations
it won't see any new migrations and will console output no changes detected
. You'll have to do python manage.py makemigrations your_app_name
instead to make things work.