I want to run a python script with the cherrypy module. I use pip install cherrypy
to install it and all looks ok. Then I click the "Run python file" button and I face the error ModuleNotFoundError: No module named 'cherrypy'
.
Trying to reinstall cherrypy I see many Requirement already satisfied
responses.
If it helps I have already edit, in the user path variables panel, the Path variable and added C:\Users\username\AppData\Local\Programs\Python\Python37-32\Scripts
as a path.
edit: I suspect some problem with the path. So i run the following.
>>> import os
>>> import sys
>>> os.path.dirname(sys.executable)
'C:\\Python25'
it returns: 'C:\\Users\\username\\AppData\\Local\\Microsoft\\WindowsApps\\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0'
pip
in the path forpip install ...
isn't for the same version of Python which is first in the path. Clean up your system or use full-paths when excuting pip and python.