For some odd reason the Python registry occasionally disappears, and when it does it prevents one from being able to install new modules via the Windows MSI installer.
Here is a quick fix that can be done to restore the registry and allow you to get back to writing some awesome Python code.
Copy the following code and paste it into the editor, or you can download this sample fix_python.reg file.
Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\Python] [HKEY_CURRENT_USER\Software\Python\Pythoncore] [HKEY_CURRENT_USER\Software\Python\Pythoncore\2.6] [HKEY_CURRENT_USER\Software\Python\Pythoncore\2.6\InstallPath] @="C:\\python26" [HKEY_CURRENT_USER\Software\Python\Pythoncore\2.6\PythonPath] @="C:\\python26;C:\\python26\\Lib\\;C:\\python26\\DLLs\\" [HKEY_CURRENT_USER\Software\Python\Pythoncore\2.7] [HKEY_CURRENT_USER\Software\Python\Pythoncore\2.7\InstallPath] @="C:\\python27" [HKEY_CURRENT_USER\Software\Python\Pythoncore\2.7\PythonPath] @="C:\\python27;C:\\python27\\Lib\\;C:\\python27\\DLLs\\"
Modify the paths to match your environment, e.g., C:\python27
Save the file to your desktop or other path.
Double-click the file, and follow the prompts to load the new values into the Windows Registry.
Voila! The Python registry has been restored.