Fail to install Python 2.7.9 on a Windows google compute engine instance
Asked Answered
L

4

7

I fired up a new Windows google compute engine instance. It's running Windows 2008 R2, service pack 1.

I download and try running the Python .msi installer for version 2.7.9, and it fails with this error:

There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor.

I see this error for both the 64-bit and the 32-bit installer.

Has anyone else seen it or know of a work-around?

Loadstone answered 9/2, 2015 at 7:35 Comment(1)
The python2.7.5 installer runs without reporting an error, but then when I look at the Python27 directory, the Scripts directory is missing!Loadstone
M
9

I reproduced your issue and I found two workarounds:

  1. You can install python 2.7.6 successfully without further action.
  2. If you need python 2.7.9 you can install it deselecting pip from the install menu. This seems to be related to this answer in another thread although in that case the issue is with version 3.4.
Madden answered 9/2, 2015 at 11:22 Comment(1)
I couldn't unselect pip, the installer kept on giving me this error when trying to change the installation. Your link to 'this answer' helped as the next most upvoted answer talks about deleting the PYTHON_HOME environment variable which helped meCohl
E
7
  1. Install python EXCEPT "pip"
  2. Run the python install msi again and select "change"
  3. Select "pip" and install the pip It would be works...

I think it is a priority problem into the msi package...the package seems to try to install the pip before installing python.exe. So, pip can not be installed...

Elly answered 7/6, 2015 at 9:39 Comment(2)
This worked for me with python-2.7.11.amd64 on Windows Server 2008R2 64bit (dedicated server, not a google compute engine instance)Illlooking
Using "change" to add pip didn't work for me with 2.7.9 64-bitCubiculum
C
1

I'm using Windows 8.1 64-bit. I had 2.7.11 installed and then I tried to install PIP as well via Chocolatey PIP package.

I think my installation had got messed up because I had tried to install Python 3.4 as well as Python 2.

Then I had deleted all the Python 2 and Python 3 files in an attempt to get rid of this.

What worked for me was:

  1. Editing the Environment Variables both, System and User to remove any PYTHONHOME or PYTHONPATH variables
  2. I also deleted the path I had to python2 in the PATH environment variable
  3. Now (as mentioned in Python Issue 22329) after deleting the Environment variables you can go into 'Programs and Features', click on the Python 2.7.11 (64-bit) program and then click 'Repair' - this then worked as I would expect without error.
  4. Now finally I was able to go into 'Programs and Features', click on the Python 2.7.11 (64-bit) program and then click 'Uninstall'.

Edit: I assume this is connected with this PYTHON_HOME answer to a problem with Python 3.4

Cohl answered 25/3, 2016 at 13:59 Comment(0)
S
0

It seems to be a dependency issue, please try to install "Microsoft Visual C++ 2008 SP1 Redistributable Package (x64)"

Sooth answered 28/6, 2015 at 18:13 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.