I have this package, setuptools, installed on my local machine as you will in the command line code attached, but I don't understand why I keep getting the modulenotfound error.
PS C:\Users\MY PC\desktop\django-polls> easy_install --version
setuptools 41.2.0 from c:\users\my pc\appdata\local\programs\python\python38\lib\site-packages (Python 3.8)
PS C:\Users\MY PC\desktop\django-polls> python setup.py sdist
Traceback (most recent call last):
File "setup.py", line 1, in <module>
from setuptools import setup
ModuleNotFoundError: No module named 'setuptools'
PS C:\Users\MY PC\desktop\django-polls> pip install setuptools
Requirement already satisfied: setuptools in c:\users\my pc\anaconda3\lib\site-packages (52.0.0.post20210125)
PS C:\Users\MY PC\desktop\django-polls> python setup.py sdist
Traceback (most recent call last):
File "setup.py", line 1, in <module>
from setuptools import setup
ModuleNotFoundError: No module named 'setuptools'
PS C:\Users\MY PC\desktop\django-polls>
CodePudding user response:
This may not work but did you try to install it in the working directory I see you have it in the "my pc" directory but maybe if you tried to install it in the working directory "django-polls" it may work then. Let me know if that does anything for you.
CodePudding user response:
If you are using a virutal environment that may be the reason you are experiencing this. Try installing the package while the VE is active. However, I am learning Django myself but figured I would give it a shot. Good luck.