Python安装scrapy进程中现身“Failed building wheel for xxx”

用61个人windows10的CMD命令安装pip install scrapy出错:

https://www.lfd.uci.edu/~gohlke/pythonlibs/#lxml

  Running setup.py bdist_wheel for Twisted … error

 

  Failed building wheel for Twisted

Python安装scrapy库进度中冒出“
Failed building wheel for xxx”的消除办法:
出现原因:缺点和失误相应的whl文件。

  Running setup.py clean for Twisted

消亡办法:下载并设置相应的whl文件。

Failed to build Twisted

1.哪些下载对应的whl文件:

Installing collected packages: pycparser, cffi, asn1crypto,
cryptography, pyOpenSSL, Twisted, pyasn1, pyasn1-modules,
service-identity, queuelib, scrapy

   
点击下方链接,就能够找到并下载相对应的whl文件:
   
Unofficial Windows Binaries for Python Extension
Packages

   
比如,现身“ Failed building wheel for
Twisted”则下载相应python版本的Twisted文件。

  Running setup.py install for Twisted … error

 
  图片 1

Exception:

 

Traceback (most recent call last):

   
在上述页面寻觅Twisted,点击跳转: 
如Twisted‑17.9.0‑cp36‑cp36m‑win_amd64.whl

  File
“e:\python\envs\py2scripy\lib\site-packages\pip\compat\__init__.py”,
line 73, in console_to_str

     
                                   
 图片 2

    return s.decode(sys.__stdout__.encoding)

*      切忌订正文件名!!*

UnicodeDecodeError: ‘utf-8’ codec can’t decode byte 0xb6 in position 30:
invalid start byte

2.就像有的时候候缺点和失误四个或三个以上文件则从后往前下载相呼应的whl文件

 

如下图,这时候应先下载zope.interface再下载twisted文件。

During handling of the above exception, another exception occurred:

图片 3

 

 

Traceback (most recent call last):

3.怎么设置相应的whl文件:

  File
“e:\python\envs\py2scripy\lib\site-packages\pip\basecommand.py”,
line 215, in main

 
 (步向虚构情况卡塔尔
   
使用  pip install “文件路线+whl文件名”就可以成功安装相应的whl文件。

    status = self.run(options, args)

    如
pip install D:\python\Twisted‑17.9.0‑cp36‑cp36m‑win_amd64.whl

  File
“e:\python\envs\py2scripy\lib\site-packages\pip\commands\install.py”,
line 342, in run

 
大概:cd踏向此whl目录,直接施行:

    prefix=options.prefix_path,

pip install Twisted‑17.9.0‑cp36‑cp36m‑win_amd64.whl

  File
“e:\python\envs\py2scripy\lib\site-packages\pip\req\req_set.py”,
line 784, in install

留意:假如在设想情况下安装,一定要先步向设想境遇再
pip install

    **kwargs

图片 4

  File
“e:\python\envs\py2scripy\lib\site-packages\pip\req\req_install.py”,
line 878, in install

 

    spinner=spinner,

 安装完以往scrapy也就顺利安装成功。

  File
“e:\python\envs\py2scripy\lib\site-packages\pip\utils\__init__.py”,
line 676, in call_subprocess

 图片 5

    line = console_to_str(proc.stdout.readline())

 

  File
“e:\python\envs\py2scripy\lib\site-packages\pip\compat\__init__.py”,
line 75, in console_to_str

参照链接:

    return s.decode(‘utf_8’)

http://blog.csdn.net/zhouyequ/article/details/73883050

UnicodeDecodeError: ‘utf-8’ codec can’t decode byte 0xb6 in position 30:
invalid start byte

http://blog.csdn.net/weixin\_34722995/article/details/70043392?fps=1&locationNum=2

减轻方法:

scrapy官方文书档案 
scrapy库安装进度

 图片 6

 

参照连接情势:

https://stackoverflow.com/questions/45830222/a-error-happened-while-pip-was-installing-scrapy

发表评论

电子邮件地址不会被公开。 必填项已用*标注

网站地图xml地图