您的位置:首页 > 运维架构 > Linux

centos7.3 安装scrapy出错Could not find a version that satisfies the requirement Twisted>=13.1.0

2018-01-31 16:17 741 查看
1错误原因,通过pip install 安装scrapy是报错Could not find a version that satisfies the requirement Twisted>=13.1.0 (from Scrapy) (from versions: )

No matching distribution found for Twisted>=13.1.0 (from Scrapy)

原因是没有安装Twisted

2.在这里需要安装twisted,可通过wget https://pypi.python.org/packages/source/T/Twisted/Twisted-15.2.1.tar.bz2

获取,然后tar -xjvf Twisted-15.2.1.tar.bz2 进行解压

注意在解压是可能会遇到tar (child): lbzip2: Cannot exec: No such file or directory

tar (child): Error is not recoverable: exiting now

tar: Child returned status 2

tar: Error is not recoverable: exiting now的错误,这是因为你没有安装bzip2,通过

yum -y install bzip2 命令安装一下就好了

3.解压之后,cd Twisted-15.2.1到目录下,通过python setup.py install 指令进行安装

4.最后直接进行pip install scrapy进行scrapy安装就行了
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐