I'm using Django 3.2. I've changed added this line to settings.py
:
DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
I then ran these commands:
$ python manage.py makemigrations
$ python manage.py migrate
The makemigrations
command creates new migration files for my apps, not just the apps that I have created, but also in my dependencies. For example, I'm using django-allauth
, and this file was created in my virtual environment (virtualenv):
.venv/lib/python3.8/site-packages/allauth/account/migrations/0003_auto_20210408_1526.py
This file is not shipped with django-allauth
. When I deploy this application from git, this file is not included.
What should I do instead? How can I switch DEFAULT_AUTO_FIELD
without the need to create new migration files for dependencies like django-allauth
?