Reputation: 81
I am new to Python. Installed Anaconda on my system. I installed PyCharm too. When I try to run a file from PyCharm I get this error message:
C:\Python\Test\venv\Scripts\python.exe python 3.6 C:/Python/Test/while.py C:\Python\Test\venv\Scripts\python.exe: can't open file 'python': [Errno 2] No such file or directory
Upvotes: 7
Views: 30681
Reputation: 24
I had the same problem with the Pycharm Community Edition (CE). Solved it by switching to Pycharm Professional.
Upvotes: -3
Reputation: 63
I had the same issue and then solved it by running PyCharm as administrator.
Upvotes: 1
Reputation: 31
Under Conda Environment, you can try to choose X:\Anaconda3\Scripts\conda.exe.
Upvotes: 3
Reputation: 131
You have mentioned that you have already installed the Anaconda in your system. You can try the following,
You should now be able to see the libraries in the Project Interpreter.
Upvotes: 13
Reputation: 41
The command you are using is wrong, try:
C:\Python\Test\venv\Scripts\python3.exe C:/Python/Test/while.py
Upvotes: -1
Reputation: 2945
It seems that you have virtual environment installed without python version. If you are new to Python, it may be better if you follow the easiest path: download python 2.7 or 3.6 from Python website.
If you run the installer, you should find the python folder in C:\Python27 or C:\Python36.
Then you should assert that this folder is in windows paths, set them in Enviromental variables in System property.
For the last step you need to set Python interpreter in PyCharm:
File -> Settings -> Build, Execution, Deployment -> Console -> Python Console -> Python interpreter
and set as interpreter the python.exe file in your X:/PythonNN folder
Upvotes: 1