Preheat the oven to 170°C/150°C fan/330°F/gas mark 4.
Place a large non-stick casserole pan over a high heat and add 1 tbsp of oil. Season the beef with salt and pepper and brown in the hot casserole in batches until the pieces are well coloured on both sides, making sure you do not overcrowd the pan. Remove each batch and set aside on a plate.
Add the remaining oil to the pan and lower the heat to medium. Toss in the onions and cook for about 10 minutes until softened and golden brown. Stir in the flour and cook, stirring, for 1-2 minutes.
Add the stout and stir well to deglaze the pan, scraping up the meat sediment. Return the beef to the pan, pour in the beef stock and add the thyme. Bring to the boil, then put the lid on the casserole and cook in the oven for 1½ hours.
Add the mushrooms to the casserole, stir well and return to the oven for a further 1½ hours.
Season with salt and pepper to taste and stir in half of the chopped parsley. Scatter over the remaining parsley to finish and serve with mash, if you like.
