For the pie filling, put the beef and onions into a large, lidded saucepan and season with salt. Pour in enough water to cover the contents of the pan and bring to the boil. Once boiling, put cover the pan with a lid, reduce the heat and simmer gently for 2½–3 hours, or until the meat is tender.
Meanwhile, for the pastry, tip the flour and salt into a bowl, and add the cubes of margarine and lard. Using your fingertips, rub the fat into the flour until the mixture has the texture of breadcrumbs, and no large lumps of fat remain. Add the water and mix with a cutlery knife until the pastry begins to come together. Add more water very gradually if needed. Knead the dough lightly, shape into a ball, wrap in clingfilm and chill in the fridge for 30 minutes, or until the beef mixture is cooked. (Alternately, blend the flour, salt, margarine and lard in a food processor until the mixture has the texture of breadcrumbs. With the motor running slowly add the water through the funnel, until the mixture starts to come together.)
Once the meat has been cooking for two hours, preheat the oven to 200C/400F/Gas 6.
Cook the potatoes in salted water until tender. Drain and set aside.
When the meat is tender, remove the pan from the heat. Ladle some of the liquid from the meat into a jug to cool. Mix together the gravy granules and meat extract, and gradually add to the cooled liquid, mixing in thoroughly. Pour over the meat, and heat gently until simmering. Once simmering, remove from the heat and leave to cool slightly.
Remove the pastry from the fridge. Cut a small amount of pastry and roll it out on a lightly floured work surface to a 3mm/â…›in thickness . Cut the pastry into thin strips. Dampen the rim of a 28 x 38cm/11in x 15in pie dish with water, and line the rim with the strips of pastry.
Strain the meat and onions, reserving the sauce. Spread the meat and onions in an even layer in the base of the dish. Layer the potatoes on top of the meat and onions. Pour the reserved sauce over the filling, until just below the top of the potatoes. Reserve any remaining sauce.
Roll the remaining pastry out on a floured work surface to a 3mm/â…›in thickness, and cut to the size of the pie dish. Brush the strips of pastry on the rim of the dish with beaten egg, and place the pastry lid on top. Press the edges to seal, and brush the lid of the pie with the remaining beaten egg. Cut a few slits in the lid of the pie to allow steam to escape.
Cook in the preheated oven for 50–60 minutes, or until the pastry is golden-brown and the filling is bubbling inside.
Serve the hot pie with the reserved sauce on the side.