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

357
Vistas
Django - cannot import name 'config' from 'decouple'

I'm trying to run this project locally but when i try manage.py makemigrations i keep getting the following error:

ImportError: cannot import name 'config' from 'decouple'

Here are my steps:

  1. Clone the repository from github
  2. Create a virtual environment
  3. Install the dependencies

I made some research but i found nothing about what could be generating that error. Can anyone help me out on this? Thanks in advance!I'm running Django 3.

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

0

You might have decouple installed in additional to python-decouple (two different packages).

If that is the case simply uninstall decouple

pip uninstall decouple

And ensure you have python-decouple installed

pip install python-decouple
over 4 years ago · Santiago Trujillo Denunciar

0

It shows the error because you are not installed the module python-decouple Just run pip install -r requirements.txt If it won't work then try it in env

pip install python-decouple

over 4 years ago · Santiago Trujillo Denunciar

0

I was using pipenv to create a virtual environment and run the Django project

pipenv install -r requiremnts.txt
pipenv shell
python manage.py runserver

Interestingly above method kept throwing error that it cannot import config from decouple

then I tried:

python -m venv myEnv
myEnv/Scripts/activate
pip install -r requirements.txt
python manage.py runserver

and this ran the project successfully. I didnt understand why this would happen as I am doing pretty much same just using pip instead of pipenv.

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