无法在我的windows 10 x64计算机中安装scrapy

2024-04-26 02:39:49 发布

您现在位置:Python中文网/ 问答频道 /正文

我在命令中得到了pip install scrapy

它说Collecting scrapy,几秒钟后我得到了以下错误:

Command "c:\python35\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\DELL\\AppData\\Local\\Temp\\pip-build-2nfj5t60\\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\DELL\AppData\Local\Temp\pip-0bjk1w93-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\DELL\AppData\Local\Temp\pip-build-2nfj5t60\Twisted\

我不能得到这个错误。在


Tags: installpipbuildlocal错误twistedcoderecord
3条回答

根据糟糕的文档,它不能在WindowsMachine上的Python3.5上运行。尝试使用Python2.7(也许在virtualenv中)看看会发生什么。在

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

使用pip3代替pip,因为您使用的是python3

用这个解决了这个问题:

  1. 从这个链接>;https://www.lfd.uci.edu/~gohlke/pythonlibs/#twisted下载与您的操作系统兼容的twist版本并将其安装到您的计算机或virsualenv。在
  2. 在命令行中:pip安装twist文件的路径***.whl
  3. 然后使用pip安装scrapy

完成了!在

相关问题 更多 >