Pycharm找不到解释器 [英] Pycharm can't find the Interpreter
问题描述
我从
下次我单击创建"时,出现错误消息,提示未找到Python,但可以从Microsoft Store安装它:
当我编写程序并单击运行"时,出现相同的消息.
在英语论坛中也描述了相同的问题.如果我理解正确的话,可执行文件的路径可能很重要.可执行文件保存在 AppData \ Local \ Microsoft \ WindowsApps
下.我也不能动.我做了所有工作,就像我的教授以前所做的那样,只是对他而言,可执行文件未保存在"Windows Apps"目录下.但通常在 Programs \ Python \ Python.exe
下.
您正尝试使用 AppData \ Local \ Microsoft \ WindowsApps \ python.exe
作为基本解释器来创建虚拟环境不是真正的Python解释器,它是Windows的某种特定快捷方式,建议从Windows应用商店安装Python.
如果我没记错的话,现代的PyCharm足够聪明,不能暗示这种假冒"行为.解释器作为虚拟环境的基础,因此请确保您使用的是可用的最新IDE版本.
我们将Anaconda和Open CV用作程序包管理器和基本库
如果已安装Anaconda,请从现有口译员中选择
...或按照darcamo的建议创建一个conda环境.
仅对他而言,可执行文件未保存在"Windows Apps"下.但通常在Programs \ Python \ Python.exe
下
您的教授正在使用从python.org安装的Python,如果您不想使用conda,也可以安装它. 3.8.6 应该是一个不错的选择.
I downloaded the student version of Pycharm from https://www.jetbrains.com/de-de/community/education/#students. We use Anaconda and Open CV as a package manager and basic library.
I have a problem with the interpreter. I open a new project and select "Pure Python" and under the bar "new environment using Virtualenv". The paths for location and base interpreter were already entered:
When I next click on "Create" an error message appears, which says "Python was not found but can be installed from the Microsoft Store: https://go.microsoft.com/fwlink?linkID=2082640":
And when I write a program and click "run" the same message appears.
The same problem was described in the English forums. The path of the executable could be important if I got that right. The executable is saved under AppData \ Local \ Microsoft \ WindowsApps
. I can't move that either. I did everything as my professor did before, only for him the executable was not saved under "Windows Apps" but normally under Programs \ Python \ Python.exe
.
You are trying to create a virtual environment using AppData\Local\Microsoft\WindowsApps\python.exe
as a base interpreter but it is not a real Python interpreter it is a some sort of a Windows specific shortcut which suggests to install Python from Windows store.
If I recall correctly modern PyCharm is smart enough not to suggest this "fake" interpreter as a base for a virtual environment so make sure you are using the latest IDE version available.
We use Anaconda and Open CV as a package manager and basic library
If you have Anaconda installed - select it from existing interpreters
... or create a conda environment as darcamo suggests.
only for him the executable was not saved under "Windows Apps" but normally under Programs \ Python \ Python.exe
Your professor is using Python installed from python.org, which you can also install if you don't want to use conda. 3.8.6 should be a decent choice.
这篇关于Pycharm找不到解释器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!