Cut the butter into small pieces. Thin out the thyme sprigs. Peel the pieces of squash and cut them into thin strips. Peel the onions and fry them in a small pan with olive oil. Set aside. In a bowl, mix the 2 flours. Add the butter, thyme and salt.
Work with your fingers until the dough becomes sandy.
Gently pour in 8cl of water little by little, while continuing to work the dough with a spatula.
Form into a ball, wrap and chill for 2 hours.
When ready to bake the pie, whisk together all the filling ingredients.
Line a buttered and floured springform pan with the dough, previously rolled out with a rolling pin. Prick the bottom with a fork.
Arrange the grilled onions on top of the pie crust.
Pour the filling on top.
Arrange the pieces of squash on the mass. Season with salt and pepper, sprinkle with pumpkin seeds and thyme leaves.
Slide into a preheated oven at 180° (160° fan oven).
Bake the cake for 45min, making sure it doesn't blacken. If it does, place a sheet of aluminum foil over it.