Beispiel #1
0
    def parse_item(self, response):
        raw_recipes = parse_recipes(response, {
            'source': self.source,
            'url': response.url
        })

        return [RecipeItem.from_dict(recipe) for recipe in raw_recipes]
Beispiel #2
0
    def parse_item(self, response):
        # skip review pages, which are hard to distinguish from recipe pages
        # in the link extractor regex
        if response.url.endswith('/review'):
            return []

        raw_recipes = parse_recipes(response, {u'source': self.source, 'url': response.url})

        return [RecipeItem.from_dict(recipe) for recipe in raw_recipes]
Beispiel #3
0
    def parse_item(self, response):
        # skip review pages, which are hard to distinguish from recipe pages
        # in the link extractor regex
        if response.url.endswith('/review'):
            return []

        raw_recipes = parse_recipes(response, {
            u'source': self.source,
            'url': response.url
        })

        return [RecipeItem.from_dict(recipe) for recipe in raw_recipes]
Beispiel #4
0
 def parse_item(self, response):
   raw_recipes = parse_recipes(response, {'source': self.source, 'url': response.url})
   return [RecipeItem.from_dict(recipe) for recipe in raw_recipes]