def __init__(self, url, *args, **kwargs):
     self.url = url
     self.response = scrape(self.url, **kwargs)
     self.soup = BeautifulSoup(self.response, 'lxml')
     self.result = [
         SmartPriceSeller(self.get_product_attrs(item))
         for item in self.products_html
     ]
 def __init__(self, url, *args, **kwargs):
     self.url = url
     self.response = scrape(self.url, **kwargs)
     self.soup = BeautifulSoup(self.response, 'lxml')
     self.result = [
         SmartPriceSeller(self.get_product_attrs(item))
         for item in self.products_html
         ]
 def __init__(self, mapper, **kwargs):
     self.mapper = mapper
     self.params = kwargs
     self.url = constants.URL_MAPPER[self.mapper]
     self.response = scrape(self._make_url(self.url), **kwargs)
     self.soup = BeautifulSoup(self.response, 'lxml')
     self.result = [
         SmartPriceResult(self.get_product_attrs(item))
         for item in self.products_html
     ]
Exemple #4
0
 def __init__(self, mapper, **kwargs):
     self.mapper = mapper
     self.params = kwargs
     self.url = constants.URL_MAPPER[self.mapper]
     self.response = scrape(self._make_url(self.url), **kwargs)
     self.soup = BeautifulSoup(self.response, 'lxml')
     self.result = [
         SmartPriceResult(self.get_product_attrs(item))
         for item in self.products_html
         ]