2

Trying to install pyad package for Python 2.7.13 (windows x64) using pip. There is pywin32 package among requirements, so we get an error:

C:\Windows\system32>pip install pyad
Collecting pyad
Using cached pyad-0.5.16.tar.gz
Requirement already satisfied: setuptools in c:\python27\lib\site-packages (from pyad)
Collecting pywin32 (from pyad)
    Could not find a version that satisfies the requirement pywin32 (from pyad) (from versions: )
    No matching distribution found for pywin32 (from pyad)

Then I install pypiwin32 which used to work in such cases:

C:\Windows\system32>pip install pypiwin32
Collecting pypiwin32
  Using cached pypiwin32-219-cp27-none-win32.whl
Installing collected packages: pypiwin32
Successfully installed pypiwin32-219

But after this I still can't install pyad with the same error as above, like pypiwin32 has never been installed:

C:\Windows\system32>pip install pyad
Collecting pyad
Using cached pyad-0.5.16.tar.gz
Requirement already satisfied: setuptools in c:\python27\lib\site-packages (from pyad)
Collecting pywin32 (from pyad)
    Could not find a version that satisfies the requirement pywin32 (from pyad) (from versions: )
    No matching distribution found for pywin32 (from pyad)

Folder C:\Python27\Lib\site-packages\pywin32_system32 exists, the pypiwin32 package seems to be installed.

Any ideas to fix this?

tm-
  • 333
  • 1
  • 3
  • 10

2 Answers2

2

You are facing pywin32 installation problem, which is a binary wheel.

You can download binary wheels of pywin32 here. You install it with

pip install pywin32-221-cp27-cp27m-win32.whl

if it is the file you have downloaded

Select the correct version with respect to your installation (Python version and 32/64 bit Python version)

You can have detailed instructions here

Community
  • 1
  • 1
Guillaume Jacquenot
  • 11,217
  • 6
  • 43
  • 49
2

pyad is declaring it needs "the pywin32 distribution package" in order to be installed. Distribution packages, i.e. something from PyPI that you can pip install, differ from Python packages, folders with an __init__.py that can be imported. The naming is confusing.

So, because it's not installed, it tries to install pywin32, but it can't find a distribution that matches your Python environment: Python 2.7 on Windows x64. On PyPI it appears like the only distributions are for Python 3.6: https://pypi.python.org/pypi/pypiwin32/220

Nick T
  • 25,754
  • 12
  • 83
  • 121
  • Versin #219 is being obtained using `pip`. As I can see, there is actually distrution for 2.7 on Windows x64: https://pypi.python.org/pypi/pypiwin32/219 – tm- May 17 '17 at 17:04
  • pypiwin32 is not pywin32. One has an extra "pi". They are listed separately. – Nick T May 17 '17 at 17:18
  • I know, that `pypiwin32` is not `pywin32`. Though it's supposed to be a replacement. Meantime `pyad` should accept this way, according to readme on GitHub: https://github.com/zakird/pyad – tm- May 17 '17 at 17:52