In the bowl of your stand mixer, whisk together the flour, sugar, baking soda, and salt.
Add cold butter, cubed, to the mix. Using the paddle attachment, blend until the mixture resembles coarse crumbs.
In a separate bowl, lightly beat the egg and mix it with buttermilk and your sourdough discard.
Gradually add the wet mixture to the dry ingredients, mixing until just combined.
Then, stir in the raisins, ensuring they're evenly distributed throughout the dough.
Turn the dough out onto a floured surface, and gently shape it into a round loaf. Transfer it to a parchment-lined baking sheet, and score a deep 'X' into the top. This traditional touch isn't just for looks; it helps the bread bake evenly.
Bake in a preheated oven at 375°F (190°C) for about 45–55 minutes. You'll know it's done when it's beautifully golden and sounds hollow when tapped on the bottom.
Let the bread cool on a wire rack before slicing and serving.