Skip to content

Commit

Permalink
get crawler
Browse files Browse the repository at this point in the history
  • Loading branch information
joergreichert committed Oct 11, 2023
1 parent cc12988 commit 0ae8280
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions 1_read_paper_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,10 @@


process = CrawlerProcess(settings)
process.crawl(OparlSpider, **spargs)
crawler = process.create_crawler(OparlSpider)
process.crawl(crawler, **spargs)
process.start()

failed = process.stats.get_value('custom/failed_job')
failed = crawler.stats.get_value('custom/failed_job')
if failed:
sys.exit(1)

0 comments on commit 0ae8280

Please sign in to comment.