So for some reason, my computer refuses to see the environment PATH variable. In the path variable, I have:
C:\Python32;
listed, along with all of the other programs, but it doesn't work if I type, "python" into the command window. However, I can type "python" into the run window, and have it run the correct interpreter (I assume because I have an environment variable for that separately...? As you can see, I don't quite understand how to customize this stuff. Any help would be appreciated!
-
3docs.python.org/using/windows.htmlBlender– Blender2011年10月12日 16:25:40 +00:00Commented Oct 12, 2011 at 16:25
-
Tried both your and lc's ideas, but it didn't work. I have the Python path listed in my environment PATH list, but typing 'python' into the command window doesn't work. I guess the real question is, "How would I configure my path variables so that I could type 'python' into a command window and start up my Python installation present in C:\Python32?"SolarLune– SolarLune2011年10月12日 18:11:29 +00:00Commented Oct 12, 2011 at 18:11
5 Answers 5
I faced the same issue.
However, in my case, I went through the documentation from python and found where I was making mistake. In the latest python versions, if you type 'python' in cmd, it will show error. At the same time, the command that worked for me was 'py'.
So I recommend anyone facing a similar problem to try this - 'py'
3 Comments
py is the Python launcher which is a utility that comes with Python installations on Windows. So, python and py are two different things. You should always be able to launch python if you have it on %PATH%.I know it's been a while, but I hope this could help someone else.
I had the same problem and the only way to making it work was running cmd or powershell as administrator.
Comments
You can confirm if python is in your environment variables by looking at the output of echo
%path%
Keep in mind that after editing the PATH variable using the control panel, you have to open a new terminal, as the setting will NOT be updated in existing terminals.
Another possibility is that you added the wrong path to the PATH variable. Verify it.
The bottom line is, if the directory of your python.exe is really in PATH, then running python will really work.
Comments
Try what is written here on the official documentation.
2 Comments
I faced the same problem. Add more specific folders to your path. For example I added this and it seemed to work out! :)
C:\Python35-32;C:\Python35-32\Lib\site-packages\;C:\Python35-32\Scripts\;
To check if it is set successfully, type python in command prompt