简体   繁体   English

我无法通过 pip 安装任何模块/VScode 找不到我刚刚下载的任何模块

[英]I can't install any module by pip/ VScode can't found any module which I've just download

I've tried so many ways to fix this problem, like I've uninstall every python version I've downloaded and reinstall python 3.10.1(Although it show me that it was 3.9.10 when I check it by windows 11 cmd but VScode show me that it was 3.10.1. I have no idea that which I should trust). I've tried so many ways to fix this problem, like I've uninstall every python version I've downloaded and reinstall python 3.10.1(Although it show me that it was 3.9.10 when I check it by windows 11 cmd but VScode 告诉我它是 3.10.1。我不知道我应该信任哪个)。 And I've also tried to install the module again and again(It said I've already install it).而且我还尝试一次又一次地安装该模块(它说我已经安装了它)。 Also I can see the module was in my computer, which mean I can see it in the file.我还可以看到该模块在我的计算机中,这意味着我可以在文件中看到它。 What's wrong???怎么了??? If you know what's happened and you know how to fix it, please tell me.如果你知道发生了什么并且你知道如何解决它,请告诉我。 I need your suggestion to fix this stupid problem.我需要你的建议来解决这个愚蠢的问题。 Thanks!谢谢!

It looks like you have multiple python environments and which environment you have installed the python modules was not which you have selected in the VSCode.看起来您有多个 python 环境,而您安装 python 模块的环境不是您在 VSCode 中选择的。

In the cmd execute where python to check all the python environments you have installed.在 cmd 中执行where python以检查您已安装的所有 python 环境。 In the VSCode click the python interpreter at the bottom-left on the VSCode to switch the python interpreter.在 VSCode 中单击 VSCode 左下角的 python 解释器以切换 python 解释器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM