Luke McCowan scored the only goal of the game after 63 minutes as Dundee picked up their first win of the cinch Premiership season, defeating Heart of Midlothian 1-0 at the Kilmac Stadium.
St Mirren moved level on points with leaders Celtic but were denied a third straight win in a 2-2 draw with Aberdeen in Paisley when Bojan Miovski converted a penalty deep into stoppage time.
Jonny Hayes gave the Dons the lead but Greg Kiltie (penalty) and Alex Grieve had Saints on course for victory until Miovski's late leveller.