Home python Windows does not change the default program for .py files

Windows does not change the default program for .py files




Reinstalled Python, recorded all the Path


The folder with its scripts threw into the folder with Python (as it was before), as prescribed it in the PATH variable so that you can run via cmd

But for some reason, Windows does not see the extension .py from scripts, that is, does not open files using python.exe opened through PCM and manually chose the program

But after selecting python.exe nothing happened, the default startup program did not change, did not appear in the recommended startup programs, through IDLE, all scripts are launched and running

In default programs, NotePad ++ is specified when you try to change and specify Python.exe. The story is repeated that I specified above

The whole Google was excised not found a solution, who knows who about something?

Answer 1, Authority 100%

Check that you are installed as an appointment application. You can do this in the “Select Standard Applications for File Types” window.

Open this window as follows (described for Windows 10 ):

  1. Run the “Control Panel”

  2. Next “Programs” & gt; “Study programs” & gt; “Mapping file types or protocols with specific programs”

  3. In the “Default Default” window appeared to the bottom and select “Select Standard Applications for File Types”.

  4. In the window that appears, find the types of files starting with “.py” and choose applications for them.

If it does not help , you will have to delete an application association and a file type manually.

  1. Run the registry editor: Enter the regedit.exe command in the command line or “Run”

  2. In the tree on the left, find the HKEY_LOCAL_MACHINE \ SOFTWARE \ CLASSES \ .py branch. If possible – open it

  3. Highlight the “OpenWithProgIDs” gate, press the PCM on it, select Delete. In the figure, I showed it to extend .pyw

  4. Check that the association with another program disappeared. In this case, a program that registered this extension must be selected is the Python interpreter

Answer 2, Authority 50%

Found a solution, suddenly come in handy to whom, through the registry, you can fix the association of files, go along the way in the registry HKEY_CURRENT_USER Software Microsoft Windows currentversion explorer fileexts .py and delete the folder UserChoice Apparently after this is reset the default value and you can select it again

Programmers, Start Your Engines!

Why spend time searching for the correct question and then entering your answer when you can find it in a second? That's what CompuTicket is all about! Here you'll find thousands of questions and answers from hundreds of computer languages.

Recent questions