I have install django in my virtual environment also activated virtual environment but still it is showing these error python
from django.urls import path
output
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
Install the latest PowerShell for new features and improvements! https://aka.ms/PSWindows
PS E:\django\project\telusko> & C:/Users/hp/AppData/Local/Programs/Python/Python39/python.exe e:/django/project/telusko/calc/urls.py
Traceback (most recent call last):
File "e:\django\project\telusko\calc\urls.py", line 1, in <module>
from django.urls import path
ModuleNotFoundError: No module named 'django'
PS E:\django\project\telusko>
CodePudding user response:
try the pip freeze command in the activated environment. It django is not present in the result use the following command
python -m pip install Django
CodePudding user response:
You have installed the django
in the virtual environment, but you are using the global python environment:
C:/Users/hp/AppData/Local/Programs/Python/Python39/python.exe