I've installed django rest framework using pip install djangorestframework
And added the rest framework to the INSTALLED_APP:
INSTALLED_APPS = [
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'rest_framework',
'rest_framework.authtoken',
]
yet I still get this error when I run python3 manage.py runserver
:
ModuleNotFoundError: No module named 'rest_framework'
And to rectify this error I have already tried all this:
1.Tried to install django rest framework using: pip3 install djangorestframework
2.Checked for ,
after adding 'rest_framework'
to INSTALLED_APPS
3.My virtual environment is active
4.I have added markdown and django-filter also using :
pip install markdown
pip install django-filter
5.Upgraded my pip using: python -m pip install --upgrade pip
6.Tried adding 'rest_framework'
as the first app in INSTALLED_APPS
7.Tried deactivating and the activating again the virtual environment
I'm using Django == 3.0.2 and Django REST Framework == 3.11.0
So now what should I do to remove this error??
runserver
command from the same terminal that you've used to install the package? – JPG