Romesco Potatoes

5 ancho chiles, stemmed and seeded
2 tablespoons hazelnuts, blanched and skinned
2 tablespoons raw almonds
1-1/2 pounds Yukon Gold potatoes
1-1/2 cups extra-virgin olive oil
5 whole unpeeled cloves garlic
2 bay leaves
6 sprigs thyme, plus 2 teaspoons fresh thyme leaves
Kosher salt and freshly ground black pepper
One 1-inch thick slice country bread
1/3 cup canned tomatoes
1 clove garlic, peeled and chopped
3 tablespoons chopped flat-leaf parsley
1-2 tablespoons lemon juice, or as needed.

Preheat oven to 375 degrees. Soak the chilies in warm water to soften, about 15 minutes, then drain and pat dry. Meanwhile, spread the hazelnuts and almonds on a baking sheet, and bake until fragrant and browned, 8-10 minutes. Remove from oven and raise heat to 400 degrees.

Place potatoes in a roasting pan and toss with 2 tablespoons olive oil, 5 whole cloves garlic, bay leaves, thyme sprigs, and 1 heaping teaspoon salt. Cover tightly with foil and roast until potatoes are tender when pierced, about 50 minutes.

Meanwhile, place a large saute pan over high heat for 2 minutes. Add 2 tablespoons olive oil and heat 1 minute. Add bread and fry until browned on both sides. Cut into 1-inch cubes, and reserve. Return pan to high heat, and add 2 tablespoons olive oil and chiles. Saute 1 minute and add tomatoes and 1/2 teaspoon salt, stirring until juices have evaporated. Remove from heat.

In a food processor, combine the nuts, chopped garlic, and bread cubes. Pulse until coarsely chopped. Add chile-tomato mixture and pulse to combine. With machine running, slowly pour in 1 cup olive oil to make a smooth puree; the mixture may separate into solids and oil. Add 1 tablespoon of the parsley and season to taste with lemon juice. Transfer to a bowl and set aside.

When the potatoes are tender, remove from heat and let potatoes and garlic cool. Squeeze the garlic from its skins and set aside. Crumble the potatoes into chunky pieces with your hands. Place a large saute pan over high heat for 2 minutes. Add the remaining 2 tablespoons olive oil and heat for 1 minute. Working in batches if necessary (do not overcrowd the pan), add the potatoes and season with thyme leaves, salt, and pepper. Fry the potatoes until crispy on one side, 6-8 minutes, then turn to brown on all sides. (If the potatoes stick to the pan, do not move them; they will eventually release.) When all the potatoes are browned, return them to the pan and add the reserved romesco sauce and garlic cloves. To serve, reheat if necessary, and toss with remaining 2 tablespoons parsley.