简体   繁体   English

安装Scrapy时出错:未指定路径

[英]Error while installing Scrapy: path not specified

I recently found out that scrapy is a great library for scraping so i tried to install scrapy on my machine, but when i tried to do pip install scrapy it installed for a while and threw me this error.. 我最近发现scrapy是一个很好的抓取库,所以我试图在我的机器上安装scrapy,但是当我尝试做pip install scrapy它安装了一段时间并且把这个错误扔给了我..

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

and

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 "d:\pycharmprojects\environments\scrapyenv\scripts\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\User\\AppData\\Local\\Temp\\pip-build-arbeqlly\\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\User\AppData\Local\Temp\pip-jdj93131-record\install-record.txt --single-version-externally-managed --compile --install-headers d:\pycharmprojects\environments\scrapyenv\include\site\python3.5\Twisted" failed with error code 1 in C:\Users\User\AppData\Local\Temp\pip-build-arbeqlly\Twisted\

So after that I went to this website and installed the tools for python.. 所以在那之后我去了这个网站并为python安装了工具..

but getting this at the end of installing: 但在安装结束时得到这个:

warning: no previously-included files matching '*.misc' found under directory 'src\twisted'
warning: no previously-included files matching '*.bugfix' found under directory 'src\twisted'
warning: no previously-included files matching '*.doc' found under directory 'src\twisted'
warning: no previously-included files matching '*.feature' found under directory 'src\twisted'
warning: no previously-included files matching '*.removal' found under directory 'src\twisted'
warning: no previously-included files matching 'NEWS' found under directory 'src\twisted'
warning: no previously-included files matching 'README' found under directory 'src\twisted'
warning: no previously-included files matching 'topfiles' found under directory 'src\twisted'
warning: no previously-included files found matching 'src\twisted\topfiles\CREDITS'
warning: no previously-included files found matching 'src\twisted\topfiles\ChangeLog.Old'
warning: no previously-included files found matching 'codecov.yml'
warning: no previously-included files found matching 'appveyor.yml'
no previously-included directories found matching 'bin'
no previously-included directories found matching 'admin'
no previously-included directories found matching '.travis'
warning: no previously-included files found matching 'docs\historic\2003'
warning: no previously-included files matching '*' found under directory 'docs\historic\2003'
error: Setup script exited with error: [WinError 3] The system cannot find the path specified: 'C:\\Program Files\\Microsoft Visual Studio\\2017\\BuildTools\\VC\\Tools\\MSVC\\14.10.25017\\PlatformSDK\\lib'

any help? 任何帮助?

Scrapy docs now recommend using Conda for Windows installation: Scrapy文档现在建议使用Conda for Windows安装:

https://doc.scrapy.org/en/latest/intro/install.html#windows https://doc.scrapy.org/en/latest/intro/install.html#windows

This error comes up when you don't have Windows SDK installed. 如果未安装Windows SDK,则会出现此错误。

When you used Build Tools or Visual Studio to compile, often you need both the C++ compiler and Windows SDK. 当您使用Build Tools或Visual Studio进行编译时,通常需要C ++编译器和Windows SDK。 In the Build Tools, there is a "Custom" installation option which enables you to select to install both C++ and Windows SDK. 在构建工具中,有一个“自定义”安装选项,使您可以选择安装C ++和Windows SDK。 In Visual Studio, you have to modify your installation to install Windows SDK. 在Visual Studio中,您必须修改安装以安装Windows SDK。

I believe you need the SDK corresponding to the the platform you are using (Windows 10 SDK for Windows 10, etc). 相信您需要与您正在使用的平台相对应的SDK(适用于Windows 10的Windows 10 SDK等)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM