Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

python is not recognised as an internal or external command [duplicate]

Tags:

python

cmd

This is a really annoying problem. I've prowled the web for solutions, but all I found was tips about changing the PATH variable, which I did, of course. My Python install directory is C:\Python27. It' a 32 bit version. Whenever I type python in the command prompt, it says that it isn't recognised as an internal or external command. Currently, my PATH variable is set to C:\Python27;C:\Python27\Lib\site-packages\;C:\Python27\Scripts. Anyone has any ideas? I run Windows 7 by the way (64 bit). I'm pretty desperate. Heck, if nothing works I guess I'll try dual-booting Linux and Windows 7...

like image 895
Ohm Avatar asked Mar 02 '13 05:03

Ohm


2 Answers

Just adding the Python path and trying again worked for me (without reboot).

MS-dos command for Python 2.7:

set PATH=%PATH%;C:\python27\

MS-dos command for Python 3.3:

set PATH=%PATH%;C:\python33\

(check if that is the folder where you installed Python).

like image 162
Timothée HENRY Avatar answered Oct 25 '22 05:10

Timothée HENRY


Quick fix: May not be the most elegant or long term fix but if you are really frustrated and just want to get it to run, just copy paste the python.exe file to your current directory. This worked for me.

like image 23
user1210233 Avatar answered Oct 25 '22 04:10

user1210233