Fresh chestnuts in shell:
With a sharp knife cut an X on the round side of each chestnut. Spread the chestnuts in one layer on a baking sheet and bake the chestnuts in a preheated 450 oven for 10 minutes, or until the shells open. Remove the chestnuts, a handful at a time, and shell and peel them while they are still hot.
Preheat the oven to 350°
In a large pan, sauté the onions, celery, sage, thyme in the butter over moderately low heat, stirring, until the vegetables are softened, add apples and the chestnuts, and cook the mixture, stirring, for 1 minute. Add the vegetable mixture to the bread pieces, tossing the mixture well, stir in the parsley and salt and pepper to taste, and let the stuffing cool completely. Add the egg and enough of the stock to just bring the dressing together.
Bake for 20 minutes covered; uncover and continue baking 15 minutes or until lightly toasted on top.