实际上需要调用get_project_settings,在已发布的代码中传递给爬虫的Settings对象将为你提供默认值,而不是你的特定项目设置。你需要编写如下内容:
from scrapy.utils.project import get_project_settingssettings = get_project_settings()crawler = Crawler(settings)
欢迎分享,转载请注明来源:内存溢出
实际上需要调用get_project_settings,在已发布的代码中传递给爬虫的Settings对象将为你提供默认值,而不是你的特定项目设置。你需要编写如下内容:
from scrapy.utils.project import get_project_settingssettings = get_project_settings()crawler = Crawler(settings)
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)