MDS Engine problems
Which prop? Engines that act up, especially new ones, use the heaviest weight material prop possible. (helps you set it for the best idle mix, and stabilizes the engine. Also carries the engine through better when clearances are tight.) Bolly Clubman series 10.5 X 5 should help. (heavy, slightly long blade, good match to a .40) I've had many engines which wouldn't idle for beans with a wood prop, that worked fine with a heavier material (same dia and pitch) prop.
How much break-in running has it had? The MDS is practically worthless for flying until its had almost 1/2 gallon through it. You HAVE to get it up to proper operating temperature durring break-in, or you're doing no good.
It may actually be getting too lean, not too rich. Some engines will continue running lean, with reduced power, sounding like they are running rich. Do you actually see a LOT of vapor comming out of the exhaust when it acts up in flight? Does trying a loop help, or make it worse? (worse... its lean.)