问题
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?
回答1:
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
回答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
来源:https://stackoverflow.com/questions/44030663/pywin32-requirement-is-not-satisfied-after-installing-pypiwin32