Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

891
Vistas
Django 3.2 exception: django.core.exceptions.ImproperlyConfigured

I'm upgrading to django 3.2 but as per it's release notes, it says:

The SECRET_KEY setting is now checked for a valid value upon first access, rather than when settings are first loaded. This enables running management commands that do not rely on the SECRET_KEY without needing to provide a value. As a consequence of this, calling configure() without providing a valid SECRET_KEY, and then going on to access settings.SECRET_KEY will now raise an ImproperlyConfigured exception.

Error: django.core.exceptions.ImproperlyConfigured: Cannot import 'users'. Check that 'apps.users.apps.UsersConfig.name' is correct.

Users apps.py:

from django.apps import AppConfig

class UsersConfig(AppConfig):
    name = 'users'

I think that error is because of such as it was working with django==3.1.7. Can someone help me to solve this? How can i check if my secret key is valid or not and also generate new if needed?

over 4 years ago · Santiago Trujillo
3 Respuestas
Responde la pregunta

0

I don't think your error is directly related to that SECRET_KEY change in your question.

AppConfig.name should be the full Python path to the application. Since you appear to have users inside an apps module, you should use 'apps.users' instead of 'users'

class UsersConfig(AppConfig):
    name = 'apps.users'
over 4 years ago · Santiago Trujillo Denunciar

0

I am having this issue suddenly with Django 3.2. Why now I am not exactly sure, but adding this to my settings.py file fixed it for me. I need to understand the structural issue causing this. It might be because our Django project contains many apps grouped together.

from django.apps import AppConfig

AppConfig.default = False

https://docs.djangoproject.com/en/3.2/ref/applications/#django.apps.AppConfig.default

You can also set this individually on at an app level. This may be a better solution. I am still missing the reasoning for why this is necessary.

from django.apps import AppConfig


class DashboardConfig(AppConfig):
    name = 'dashboard'
    default = False
over 4 years ago · Santiago Trujillo Denunciar

0

The solution for me was to simply delete the apps.py file entirely - Django now managed to find the app automatically.

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda