0

I'm trying to follow along the scrapy install instructions here. When I got to installing lxml I realized I had inadvertently installed the 32 bit version of Python 2.7.9. I tried to uninstall this version using the installer and received the error "there is a problem with this windows installer package. A program run as part of the setup did not finish as expected. contact your support personnel or package vendor." so i tried to install the 64 bit version of 2.7.9, but it would only let me if I unselected the pip package. so now i have a wrong version and an incomplete version. what i would like to do is just uninstall all of them and start from scratch.

  • what does `it would only let me if I unselected the pip package` mean? – Padraic Cunningham Feb 06 '15 at 21:00
  • if i attempt to install 64 bit version i receive same error message as when i attempt to uninstall 32 bit version unless i have pip package checkbox deselected. once deselected i can install the 64 bit version – Elroy Flubbard Feb 06 '15 at 21:07
  • then just deselect, why are you worried about that? – Padraic Cunningham Feb 06 '15 at 21:19
  • because i need pip to install scrapy. when i type "pip install scrapy" from the command prompt it returns "importerror: no module named site". i have followed the instructions given in the accepted answer here: {link}(http://stackoverflow.com/questions/23708898/pip-is-not-recognized-as-an-internal-or-external-command-installing-django-w) to no avail. – Elroy Flubbard Feb 06 '15 at 21:33
  • You can install pip using get-pip.pyhttps://pip.pypa.io/en/latest/installing.html#install-pip – Padraic Cunningham Feb 06 '15 at 21:46
  • i have get-pip.py in the Python27 directory. When I type : python get-pip.py from this directory it returns: ImportError: No module named site – Elroy Flubbard Feb 06 '15 at 21:49
  • Have you installed the 64bit python? – Padraic Cunningham Feb 06 '15 at 22:00
  • Have you set your pythonpath? – Padraic Cunningham Feb 06 '15 at 22:05
  • My system variable path variable value is: C:\Python27\;C:\Python27\Scripts;... – Elroy Flubbard Feb 06 '15 at 22:08
  • Can you start a python shell from any directory? – Padraic Cunningham Feb 06 '15 at 22:10
  • i have never succeeded in doing so. the error is always the same as above. – Elroy Flubbard Feb 06 '15 at 22:24
  • Then your path must be wrong. Check it thoroughly. Does the python27 dir exist and contain everything it should? – Padraic Cunningham Feb 06 '15 at 22:25
  • As referenced at this link: https://docs.python.org/2/using/windows.html I have set the path from the command prompt like this : ' set PYTHONPATH=%PYTHONPATH%;C:\My_python_lib' where My_python_lib corresponds to the directory containing the python executable. Since this was already the mapping set for this variable this of course has done nothing. – Elroy Flubbard Feb 06 '15 at 22:33
  • Try set PYTHONPATH=c:\Python27\Lib – Padraic Cunningham Feb 06 '15 at 22:47
  • This has not changed anything. I still get the same error message – Elroy Flubbard Feb 06 '15 at 23:02
  • Is site.py in the folder? – Padraic Cunningham Feb 06 '15 at 23:05
  • Have you logged out and in since installing? – Padraic Cunningham Feb 06 '15 at 23:14
  • yes just tried again too nothings changed – Elroy Flubbard Feb 06 '15 at 23:41
  • What happens running the Python executable while in the same directory? – Padraic Cunningham Feb 06 '15 at 23:49
  • ImportError: No module named site – Elroy Flubbard Feb 06 '15 at 23:53
  • I would manually completely remove all traces of the python install then reinstall. Where did you get python from? – Padraic Cunningham Feb 06 '15 at 23:54
  • when i attempt to remove python (through the installer or through add remove programs) i receive the following error: "there is a problem with this windows installer package. A program run as part of the setup did not finish as expected. contact your support personnel or package vendor." – Elroy Flubbard Feb 07 '15 at 00:01
  • i downloaded it through the link directed from the scrapy site – Elroy Flubbard Feb 07 '15 at 00:01
  • https://support.software.dell.com/authentication-services/kb/119869 – Padraic Cunningham Feb 07 '15 at 00:05
  • i dont see how that is relevant, though i dont really understand what that is talking about either – Elroy Flubbard Feb 07 '15 at 00:09
  • It is one of thousands and thousands of posts when you google the error you are getting and considering you are using an MSI to install I imagine it is somewhat related – Padraic Cunningham Feb 07 '15 at 00:13
  • `PYTHONPATH` is irrelevant; it's for adding custom user directories to `sys.path`. Your installation seems hopelessly broken. I'd remove it manually from an elevated command prompt. Remove the directory: `rd /q /s C:\Python27`. Delete the 2.7 user registry key (if any): `reg delete HKCU\Software\Python\PythonCore\2.7 /f`. Delete the 2.7 machine registry key (if any): `reg delete HKLM\Software\Python\PythonCore\2.7 /f`. Then download and run the official [Windows x86-64 MSI installer](https://www.python.org/ftp/python/2.7.9/python-2.7.9.amd64.msi). – Eryk Sun Feb 07 '15 at 10:13
  • So I ran those commands..The user registry key did not exist but the machine registry key did. The installer you linked was the same I had. I first used it to uninstall python27 64 bit. Then I attempted to install it and received the same error I have been receiving:"There is a problem with this Windows Installer package..." – Elroy Flubbard Feb 09 '15 at 01:42
  • Make sure the `C:\Python27` directory is removed, so that you're not leaving in place any directories that could have an incorrect owner or ACLs. Then run the msi manually from an elevated (run as administrator) command prompt: `msiexec.exe /i python-2.7.9.amd64.msi`. – Eryk Sun Feb 09 '15 at 08:12
  • I tried this to no avail. Additionally, when I go to add remove programs, the 32 bit version is still there. When I try to remove it from here it errors out. When I try to change it to remove just pip it errors out. When I try to install the 64 bit version (from anywhere) it errors out. When I install all features except for pip it successfully installs. – Elroy Flubbard Feb 09 '15 at 15:25

0 Answers0