0

So, I upgraded my django version from 1.11 to 2.2 and ran python manage.py runserver. I get the error:

Model class <project_app_name>.models.<model_name> doesn't declare an explicit app_label and isn't in an application in INSTALLED_APPS.

Obviously, all apps are registered including the <project_app_name>. So, the answers that try the solution of adding the app to the installed apps don't apply here.

Any help would be appreciated

EarlyCoder
  • 1,213
  • 2
  • 18
  • 42
  • is /apps.py configured correctly? – figbar Jul 05 '20 at 01:30
  • It has its default setting: ```class ProjectProfileConfig(AppConfig): name = 'project_profile'``` – EarlyCoder Jul 05 '20 at 17:10
  • @EarlyCoder - how did you resolve this issue? I am ending up with same issue upgraded python 2.7 to 3.7 and Django 1.6 to 2.1.15, peroject_aap_name is configured in INSTALLED_APPS. – Shraddha Agrawal Oct 13 '20 at 12:58
  • @ShraddhaAgrawal I have yet to upgrade, so the issue is not resolved for me yet. If you find a way, I'd appreciate if you could post it as an answer to this question – EarlyCoder Oct 13 '20 at 16:21
  • @EarlyCoder - Okay, for me along with this error one more error was present in traceback so I solved other errors that were popping up along with this error and this error disappeared for me. Make sure to remove "import django django.setup()" from settings.py if you have used it to debug. – Shraddha Agrawal Oct 29 '20 at 10:08

0 Answers0