Is it ok to use milk that incubated for 12 hours but did not set for yogurt in baked goods?
From a conservative food safety perspective, the answer is no. The USDA suggests you discard any milk in your fridge after a 4 hour power outage -- surely your 12 hour incubation has more potential for bacterial growth. Baking is not a sufficient substitute for sterilization. Although the internal temperature of your baked good will probably reach boiling, it will not stay there long enough to guarantee all harmful bacteria are destroyed.
In yogurt making, you rely on cultured bacteria to acidify your milk. This acidity not only &quot;sets&quot; the yogurt, but protects it from the growth of further harmful bacteria. If your yogurt did not set, it is likely that the cultured bacteria is dead; perhaps you got a bad starter, or maybe you overheated it. In any case, there is not sufficient acid in your old milk to protect from harmful bacteria.
Some cooks regularly use slightly spoiled or soured milk, like Dan Barber in this interview. Pasturized milk goes bad in a fairly consistent way: according to this National Geographic article, first it goes through a souring processes with the growth of Streptococci and Lactobacilli. Only then do yeasts, molds, and Bacillus bacteria begin to grow, usually resulting in a strong smell of ammonia. The Streptococci and Lactobacilli are safe to consume (in fact, they are the same bacteria you tried to introduce to your yogurt), but the Bacillus can cause foodborne illness. This supports the idea that &quot;slightly&quot; spoiled milk could be relatively safe.
However, I would highly recommend you simply discard spoiled or possibly spoiled milk. It is a shame to waste milk, but hopefully once you perfect your yogurt making process this will be a rare occurrence. Ultimately, milk is pretty cheap and foodborne illness is pretty unpleasant. If you want to use a fermented milk product in your baking, just buy some: store-bought cultured buttermilk is safe, cheap, consistent, and delicious.