I solved the same problem with these steps :
- Delete your database (
db.sqlite3in my case) in your project directory - Remove everything from
__pycache__folder under your project subdirectory - For the application you are trying to fix, go to the folder and clear
migrationsand__pycache__directories
When you are sure you have cleared all the above files, run:
python manage.py makemigrations
python manage.py migrate