Skip to content

Set up APScheduler for hourly execution #13

Description

@Col20s

Description:
Create scrapers/scheduler.py to run Scrapy spiders on hourly schedule.

Job:

  • Every hour, trigger all 3 spiders
  • Log job status
  • Catch exceptions

Implementation:

from apscheduler.schedulers.background import BackgroundScheduler

scheduler = BackgroundScheduler()
scheduler.add_job(run_spiders, 'cron', hour='*', minute='0')
scheduler.start()

Acceptance Criteria:

  • Scheduler runs without errors
  • First run at top of hour confirmed
  • Can verify via logs

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions