when i use pip list
in vscode i found it in modules lis
requests 2.32.3
once try to use it i get
ModuleNotFoundError: No module named ‘requests’
i tried to install it again using cmd
in windows and it installed but got the same error
tried to upgrade it using pip install requests --upgrade
it didn’t work
closed vscode and reopend it and also same error
2
Answers
One suggestion I could give is to use the same virtual environment where you install a requests module.
You can try using the interactive Python shell in your CMD to verify your installation.
In the same CMD where you executed
pip list
, runpython
orpython3
, and then try the following:If this works without any issues, I’d like to clarify something important:
The Python environment used when you run code via the "Run" option in the VSCode menu might not be the same as the one used in the VSCode terminal.