I created an 'account' app in my project and I add to installed app and this code;
INSTALLED_APPS = [
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.sites',
'account',
'allauth',
'allauth.account',
'allauth.socialaccount',
]
And, I run this project (python manage.py runserver
), I have one problem:
django.core.exceptions.ImproperlyConfigured: Application labels aren't unique, duplicates: account
I not have seen before this problem and I don't have any idea.
Specify a new app config--Django Doc in your account/apps.py file
# account/apps.py
from django.apps import AppConfig
class AccountConfig(AppConfig):
name = 'account'
label = 'any_unique_name'
and update your INSTALLED_APPS
settings as,
INSTALLED_APPS = [
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.sites',
'account.apps.AccountConfig', # change this
'allauth',
'allauth.account',
'allauth.socialaccount',
]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With