I just opened a new Djangoproject with v3.2 and tried to import my apps as usual, when I got an ImproperlyConfigured Exception on one of my apps.
Steps:
- create and activate env, pip install django (without version number defaults to v3.2 as of now)
- django-admin startproject project
- mkdir project\apps, mkdir project\apps\core
- django-admin startapp core project\apps\core
- migrate, if necessary
- Go to settings and add 'apps.core' to INSTALLED_APPS
The result, when trying to runserver
\lib\site-packages\django\apps\config.py", line 246, in create
raise ImproperlyConfigured(
django.core.exceptions.ImproperlyConfigured: Cannot import 'core'. Check that
'apps.core.apps.CoreConfig.name' is correct.
Structure
-- project
-- apps
-- core
-- apps.py
-- project
-- manage.py
core\apps.py
class CoreConfig(AppConfig):
default_auto_field = 'django.db.models.BigAutoField'
name = 'core'
The auto_field seems to be new as it was not integrated in earlier versions, however, this should not affect the importation if I understand this correctly.
I returned to v3.1.3 to check if something else went wrong, but it is working fine with this approach.
Does anyone have the same issues or have a solution?
Thanks