1 Star 0 Fork 2

ba1690/Crawl_3rd_party_stores

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
run.py 699 Bytes
一键复制 编辑 原始数据 按行查看 历史
kejane 提交于 2020-07-26 22:40 . run the spider
from scrapy.utils.project import get_project_settings
from scrapy.crawler import CrawlerProcess
from scrapy.mail import MailSender
# from scrapy import settings
if __name__ == '__main__':
setting = get_project_settings()
mailer = MailSender.from_settings(setting)
process = CrawlerProcess(setting)
didntWorkSpider = ['']
for spider_name in process.spiders.list():
if spider_name in didntWorkSpider:
continue
print("Running spider %s" % (spider_name))
process.crawl(spider_name)
mailer.send(to=["646861172@qq.com"], subject='%s is finished' % spider_name, body="Please check the server", cc=["lou_jd@outlook.com"])
process.start()
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Python
1
https://gitee.com/ba1690/Crawl_3rd_party_stores.git
git@gitee.com:ba1690/Crawl_3rd_party_stores.git
ba1690
Crawl_3rd_party_stores
Crawl_3rd_party_stores
master

搜索帮助