Add the flour and baking block to a food processor and pulse until the mixture resembles breadcrumbs, with a few pea-size pieces of baking block remaining. Sprinkle with 3 tbsp ice-cold water and pulse until the dough is crumbly but holds together when squeezed. If it’s still dry, add up to 3 tbsp more ice-cold water, 1 tbsp at a time, pulsing once and checking after each addition. Form the dough into a 1-inch thick rectangle, wrap tightly in plastic and refrigerate for 30 minutes.
Place the chicken breast in a kitchen bag and bash lightly with a rolling pin to flatten slightly – the aim is to make it roughly even in thickness. Heat a large frying pan over a medium heat and coat with the olive oil. Cook the chicken in the pan without moving for 4 minutes, then flip and cook for another 3-4 minutes or until cooked through and no longer pink. Remove from the pan, cover and leave to rest.
Add the onion to the pan and cook for 6-8 minutes until softened. Add the spinach to the pan and cook until it wilts – you might need to do this in two parts depending on the size of your pan. Sprinkle over the ½ tbsp flour and stir to combine. Add 75ml water and bring to a boil, stirring often for 1-2 minutes until the mixture thickens. Transfer the wilted spinach and onion mixture to a medium bowl and add the chopped ham. Shred the chicken and add to the bowl with a light seasoning of black pepper. Stir together, cover and set aside.
Preheat the oven to 170°C/gas mark 4. Remove the pie dough from the fridge and roll out until 1/8 inch thick. Cut into 14cm wide circles – you should be able to get 8 in total by re-rolling the scraps. Place a good sized tbsp of mixture on to the lower half of each circle of dough, making sure to leave space around the edge. Fold over the top half of the circle and enclose by crimping the edges with your fingers.
Line two medium baking trays with greaseproof paper and place 4 pies on each tray. Using a sharp knife, carefully cut three slits into the top of each pie, then brush with the beaten egg. Transfer the trays to the oven and bake for 25-30 minutes or until golden brown and flaky looking. Let the pies cool on a wire rack before serving.