tutorial-pyconus2024-gather.../code/exercise-1.py
2024-05-12 10:18:16 -03:00

15 lines
No EOL
368 B
Python

import scrapy
class QuotesSpider(scrapy.Spider):
name = "quotes"
allowed_domains = ["quotes.toscrape.com"]
start_urls = ["https://quotes.toscrape.com"]
def parse(self, response):
# 1. Get the list of quotes availabe at the page
# 2. Parse each quote found and yield the quote item
# 3. Follow the next page link
...