0

as I'm using pyenv-virtualenv I have created my Pipfile and I'm trying to run the server with the command pipenv run python manage.py runserver but I'm getting the error: from decouple import config, Csv ImportError: No module named 'decouple'.

I have installed the module python-decouple and I have written the packages in my pipfile as well. I used the command pip freeze > requirements.txt

pipfile

When I run the server with the command python manage.py runserver I don't get that error. I think that I have to use the command pipenv run python manage.py runserver if I'm using pyenv. Any ideas to solve this issue?

[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"

[packages]
django = "*"
python-decouple = "*"
psycopg2-binary = "*"
django-cors-headers = "*"
djangorestframework = "*"
drf-base64 = "==2.0"
pillow = "*"
six = "==1.16.0"
django-naomi = "*"
gunicorn = "*"
xhtml2pdf = "*"
drf-yasg = "*"

[scripts]
server          = "python manage.py runserver"
startapp        = "python manage.py startapp"
migrate         = "python manage.py migrate"
makemigrations  = "python manage.py makemigrations"
createsuperuser = "python manage.py createsuperuser"

[dev-packages]


[requires]
python_version = "3.8"

miriam
  • 1
  • 1

0 Answers0