New project: Food price scraper

I’ve created a deeply middle-class Git scraper project which tracks the prices of a basket of goods sold by the British online supermarket, Ocado.

For example, Lurpak butter:


I’ve been looked for an excuse to use Git scraping for ages, and this idea came up as my wife and I were commiserating over how much food prices are increasing at the moment.

The project is the codeinthehole/food-scraper repo — see, in particular, the product overview file.

It uses Github actions to call a Python CLI application once a day that:

  1. Fetches prices for a list of products.
  2. Updates a price archive file if any prices have changed.
  3. Builds a price chart image file for each product (using matplotlib).
  4. Updates an file that collates all the chart images.

Any changes are committed back to the repo.

Ultimately, it’s an act of contortion, but it’s neat to be able to build a simple scheduler project that doesn’t require a database and runs for free on Github.


Something wrong? Suggest an improvement or add a comment (see article history)
Tagged with: Git
Filed in: projects

Previous: OpenAI Git poetry
Next: Creating pull requests with GPT3 and random artwork

Copyright © 2005-2023 David Winterbottom
Content licensed under CC BY-NC-SA 4.0.