如何scrapy shell
在PyCharm IPython控制台中运行仿真?我想保持通过Alt + Shift + E从编辑器运行代码段的能力
我通过运行以下python代码段使其工作:
from scrapy.cmdline import execute
import sys
sys.argv = ['scrapy', 'shell', 'http://scrapy.org']
execute()
如果出现以下错误:
MultipleInstanceError: Multiple incompatible subclass instances of InteractiveShellEmbed are being created.
那么您必须在scrapy.cfg中添加以下行:
shell=python
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句