Scrapy: First Spider not working

quotes_spider not working.

Code is executing right, but DEBUG doesn’t show the names of saved files on terminal and files are not saved as well.

My code:

import scrapy

class QuotesSpider(scrapy.Spider):
name = “quotes_spider”

def start_request(self):
    urls = [
        "http://quotes.toscrape.com/page/1/",
        "http://quotes.toscrape.com/page/2"
    ]
    
    # Generator Function
    for url in urls:
        yield scrapy.Request(url=url, callback=self.parse)
        
def parse(self, response):
    page_id = response.url.split("/")[-2]
    filename = "quotes-%s"%page_id
    with open(filename, 'wb') as f:
        f.write(response.body)
        
    self.log('Saved File -> %s'%filename)

hi sahil
are u running the file like : scrapy crawl quotes_spider
also are u working on project directory structure

create ur first project using after installing scrapy
“scrapy startproject tutorial” tutorial = project name

after that create quotes_spider file and try running code