It was pain at Palmerston as St Johnstone’s miserable Premier Sports Cup start continued.
The Perth side had fought back twice - thanks to Jamie Murphy on both occasions - for a 2-2 draw.
But Queen of the South were very unfortunate not to take all three points in the 90 minutes and there could have been no complaints if that had been the case.
Lee Connelly had opened the scoring for the hosts in the first half and that is how the scoreline stood at the interval.
A piece of individual talent from Murphy pulled Saints level but Ruari Paton later nudged in from close range.
Murphy again hauled Saints back with a delightful curling effort from the edge of the box to send the game to penalties.
It was Queen of the South who kept their composure to claim the bonus point.
There were three changes to the Perth team-sheet from Tuesday night’s disappointing group opener against Annan.
Dan Cleary dropped out completely after his red card while Max Kucheriavyi and Theo Bair, who also started, had to settle for a spot on the bench.
James Brown was given the nod from the first whistle on the right of a defensive three and, in a more advanced area of the pitch, Graham Carey was handed his starting debut. Stevie May led the line.
Saints’ trips to this venue have not always gone to plan and the last one, in season 2018/19, required extra-time to eventually edge a 4-2 win. A few years earlier the Doonhamers had celebrated a 2-0 Scottish Cup triumph.
They went closest to boasting an early advantage when a mix-up in the middle of the park between Murray Davidson and Melker Hallberg kick-started the counter-attack.
The ball was worked to Paton who, driving into the box, could only find the side-netting with his effort.
Saints were forced into a change in just the 10th minute when Ali Crawford hit the turf off the ball. He was replaced by Murphy.
Not long after, Ciaran McKenna had the freedom of Dumfries to deliver from the right for Connelly to nod, with the aid of a deflection, beyond Elliott Parish.
In search of a quick response, Hallberg’s corner eventually found May deep inside the box. Despite being grounded he swung his boot at the ball and hit the woodwork.
As the half progressed, Saints continued to offer very little going forward and the hosts looked far more threatening on the counter attack.
Connelly was a menace and just shy of the break nudged into the path of Paton who, luckily for the Perth men, was unable to get his feet sorted quick enough before sending a weak effort into Parish’s gloves.
Queen of the South fully deserved their half-time advantage.
Michael O’Halloran was introduced for the start of the second half, replacing Charlie Gilmour at right wing-back.
But it was a moment of magic from Murphy with 50 minutes played that hauled Saints back into this contest.
He embarked on a solo run deep into the box, navigating beyond numerous home defenders, before guiding low across Max Currie with his left foot.
Andrew Considine then quickly looked for another when latching onto Hallberg’s corner but his header was narrowly wide of the mark.
Queen of the South, however, regained their lead in the 65th minute and Perth defending was again all at sea.
A knockdown from a corner found Paton - he had completely lost whoever was supposed to be marking him - who guided home from close range.
Max Kucheriavyi and Theo Bair were quickly called from the bench. Carey and May departed the action.
It could have got worse for Saints with little over 10 minutes remaining if Connelly’s curling effort had navigated inside the far post. Then he missed a one-on-one with Parish, hitting the outside of the post.
That would come back to bite when, in the 85th minute, Murphy took matters into his own hands again. He curled in off the post from the edge of the box to level the game at 2-2.
It would go to penalties to decide the bonus point and Queen of the South claimed it. Davidson and Kucheriavyi missed for Saints.