Preheat oven to 140C. Heat olive oil in a large casserole over low-medium heat, add pancetta, onion and garlic and cook, stirring occasionally, until vegetables are tender (1 hour). Add tomato paste and stir occasionally until paste darkens (3-5 minutes), then add wine, Madeira and thyme, season to taste and stir to combine. Keep warm.
Cook duck skin-side down in a large non-stick frying pan over medium-high heat until fat renders and skin is golden (15 minutes), then transfer duck to casserole (discard fat). Add stock, then cover casserole with baking paper and foil or a lid and braise in oven until duck falls from the bone (3 hours). Remove duck from stock, cool slightly, then shred meat (discard skin), transfer to a bowl and refrigerate until required. Refrigerate stock for 2-3 hours, then skim fat from surface. Bring stock to the boil in a saucepan over high heat, then season to taste, add shredded duck, stir to combine and keep warm.
For pappardelle, blend flour, eggs and a large pinch of salt in a food processor until a dough forms, then transfer to a bench and knead into a smooth ball. Wrap in plastic wrap, flatten to a disc and set aside to rest (30 minutes). Working with a quarter of the dough at a time, roll through a pasta machine to the second-to-last setting, then, using a pasta wheel, cut 2.5cm-wide strips, lightly flour and hang over a chair while you roll remaining dough. Cook pappardelle in a large saucepan of boiling salted water until al dente (1-2 minutes). Drain, reserving a little pasta water, then toss pasta in sauce, adding a little reserved cooking water if necessary. Serve pasta and ragù scattered with pecorino.