Heat oven to 400°F.
Bring 2 cups of water in a medium pan to a boil over high heat. Add the onions and cook for 1 minute. Drain. When cool enough to handle, use a knife to snip off the ends of the onions. Use your fingers to gently squeeze the onion out of the skin. Set aside.
Heat 3 tablespoons of oil in a large saucepan/skillet over medium-high heat. Add onions and mushrooms and a good pinch of salt and pepper and sauté, stirring occasionally, until nicely browned and soft, about 10 to 12 minutes.
Add vinegar and sugar to the skillet and simmer. Stir frequently with a wooden spoon to scrape any browned bits stuck to the bottom of the skillet. Cook until sauce thickens slightly and comes almost like syrup, just a few minutes.
Rub haddock fillets with the remaining 2 tablespoons of oil, then season with salt and pepper. In a non-stick skillet, heat a little oil over medium heat.
When the skillet is hot, add fillets, skin side up, and sear until lightly browned on the bottom, about 4 minutes. Remove from heat and place the fish, seared side up, in a baking dish. Pour the mushroom agrodolce sauce all over the fish and top with the sprigs of thyme.
Place in oven and roast until fish is cooked through, about 10 minutes. Remove from oven and discard the thyme sprigs on top. Plate and garnish with a pinch of chopped fresh thyme. Serve at once.
