Running Python script from command line opens script in the default text editor instead of executing script
问题 I have files with .py extension associated with Python interpreter. However when I type name of such a file at the command line and press ENTER the file is being opened in the default text editor (Notepad++) instead of being run with the associated Python interpreter. Why? Z:\1>where python c:\Program Files\Python\2.7\python.exe Z:\1>reg query HKCR\.py /ve HKEY_CLASSES_ROOT\.py (Default) REG_SZ Python.File Z:\1>reg query HKCR\Python.File\shell\open\command /ve HKEY_CLASSES_ROOT\Python.File