This week's offers at Lidl

from urllib.request import urlopen from lxml import html url = 'https://www.lidl.de/de/angebote' page = urlopen(url).read().decode('utf-8') tree = html.fromstring(page) item_prices = {} links = tree.xpath('//div[contains(@class, "space")]/a') for link in links: item = link.xpath('.//span[@class="desc-height"]/strong/text()') b = link.xpath('.//span[@class="price-height"]/span/b') if item and b: item, b = item[0], b[0] euro = b.xpath('./text()') cents = b.xpath('./sup/text()') if euro: euro = euro[0].strip().replace('-', '0') if cents: cents = cents[0].strip().replace('-', '').replace('*', '') if euro and cents: price = float(''.join([euro, cents])) item_prices[item] = price for item, price in sorted(item_prices.items(), key=lambda x: x[1]): print("%6.2f€ %s" % (price, item)) """ 1.29€ Kartoffelspalten 1.29€ Gourmet-Burgersauce 1.69€ Antipasti 1.69€ Burgerscheiben mit Cheddar 1.99€ Grillkäsetaler 1.99€ Rustico-Burger 2.69€ Schweinerückensteak 2.89€ Schweinenackensteaks 2.99€ Double Quarter Pounder 2.99€ US-Angus-Burger 2.99€ Hähnchen-Minutenschnitzel 3.49€ Cuvée Muschelkalk Mosel QbA halbtrocken, Weißwein 3.99€ ERNESTO® Küchenhelfer 3.99€ Allini Pinot Grigio Vino Spumante Brut, Schaumwein 2016 4.20€ Spare Ribs 4.99€ Nero d'Avola Terre Siciliane IGP, Rotwein 2016 5.99€ SILVERCREST® Elektrische Salz- und Pfeffermühle 6.99€ ERNESTO® Messer 7.99€ Sunrise Paket 7.99€ Lemon Flavoured Vodka 40% Vol 11.99€ Unsi Terrazas Garnacha de Montaña trocken, Rotwein 2014 11.99€ ERNESTO® Guss- / Grillpfanne 13.99€ Tequila Paket 15.99€ Ypióca Empalhada Ouro Cachaca 38% Vol 20.99€ Tacama Pisco Acholado Demonio de los Andes 40% Vol 49.99€ SILVERCREST® Kontaktgrill-LED SKGL 2000 A1 """

Note: Depending on the design of the page and future changes introduced to it, you may need to select different tags if you use this code. Otherwise you can run it every other week to see the new offers without having to download heavy images. At the time of writing, this page makes 122 requests, weighs 4.9MB and finishes loading in 29.32s.