In a blender, combine the mangoes, onion, vinegar, water, brown sugar, allspice, and salt and purée until smooth.
Add one habanero, blend, and taste to see if you want to add more heat. If it isn’t too hot for you, add the second one—or part of it—and blend until smooth. Keep in mind that cooking the salsa tames the heat a bit, and it will calm down a little more as it sits.
In a medium saucepan over medium heat, warm the oil. Add the mango mixture, cover partially (the salsa will splatter a lot), and cook, stirring occasionally and scraping the bottom of the pan to prevent scorching, until the salsa resembles a thick pudding and coats the back of a wooden spoon quite heavily, about 15 minutes.
Remove from the heat and allow to cool before serving. The salsa will keep, tightly covered, for 5 to 7 days in the refrigerator.