windows install scrapy

1. Install Twisted

Direct pip install Twisted

then error

    error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools

    ----------------------------------------
Command "c:\users\zb\appdata\local\programs\python\python36-32\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\zb\\AppData\\Local\\Temp\\pip-build-10ew2ma_\\Twisted\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\zb\AppData\Local\Temp\pip-85cixft1-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\zb\AppData\Local\Temp\pip-build-10ew2ma_\Twisted\
You are using pip version 9.0.1, however version 10.0.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.

 

The last sentence boost lets upgrade pip, then run python -m pip install --upgrade pip run 

At this point we have successfully upgraded pip. Then reinstall pip install twisted and see the following error after running

    building 'twisted.test.raiser' extension
    error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools
Literally , Microsoft Visual C++ 14.0 needs to be installed, but this thing is very troublesome to install, and the installation is not necessarily accurate. At this time, we generally consider the third-party python module installation package
http://www.lfd. uci.edu/~gohlke/pythonlibs/

Then search for twisted, download the corresponding version, the following figure cp36 is for python3.6x version, win32 refers to the number of digits of python, cmd input python to check the version of python, here I will download the following blue x

 https://download.lfd.uci.edu/pythonlibs/t5yhk4lc/Twisted-18.4.0-cp36-cp36m-win32.whl

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325312791&siteId=291194637