A stoppage-time strike from Birkir Bjarnason gave Aston Villa a 3-2 victory over a Wigan Athletic side who gave everything and will certainly felt they did enough for at least a point.
The home side had taken the lead with only 13 minutes gone when Jack McGinn’s free-kick was nodded into the net by James Chester, who’d stolen a march on Nick Powell.
While Villa enjoyed the majority of the ball in the first half, Latics remained a threat on the counter, and they were level four minutes before the break.
Mile Jedinak’s backpass was woefully short, allowing the alert Powell to race in on it.
As Orjan Nyland came off his line to clear, Powell put in a textbook block tackle, and the ball flew straight back past the helpless Villa goalkeeper into the empty net.
Latics went ahead within 10 minutes of the restart, when Powell’s cross was headed home at the far post by Everton loanee Callum Connolly, marking his second ‘debut’ with a goal, just as he had (twice) on his original bow two seasons ago.
But Villa fought hard and were level eight minutes later, when a right-wing corner from McGinn was bundled home at the far post, with Latics centre-back Chey Dunkley looking like he’d got the final touch.
Both sides had great chances to win it - Latics through substitute Josh Windass, whose diving header flew just over the bar - and it looked as though both sides would have to settle for a point.
But right at the death, Bjarnason couldn’t miss from close range, after being teed up by substitute Conor Hourihane, to break the hearts of Latics and their near-1,400 travelling contingent.
After last weekend’s win by the odd goal in five over Sheffield Wednesday, Cook’s men this time found themselves on the wrong side of the result.
But they’ll have travelled back up north safe in the knowledge that, if they play like this for the rest of the season, there’ll be more good days than bad.
The afternoon had started on a nervy note, with a Villa cross from the left being spilled by Christian Walton, who was grateful to team-matre Cedric Kipre for getting his pal out of jail by lashing clear.
At the other end, Callum McManaman - making the first start of his second spell with Latics - fed Michael Jacobs, who tried his luck on the volley from 25 yards only to send it wide.
The deadlock was eventually broken on 13 minutes, and Latics were left choking on a sense of injustice.
Connolly appeared to make little or no contact with Jack Grealish just inside the Wigan half, but the Villa man tumbled to the deck, the referee blew his whistle, the free-kick went in, and Chester nodded home from 12 yards.
There followed a massive Latics shout for a penalty for handball against Chester with Reece James, Will Grigg, Powell - plus the Latics management - all going straight up, only for play to go on.
Jacobs then supplied two decent openings from the left, the first being sent wide by Powell and the second being directed goalwards by the same player, only for a defender to hack it off the line.
Villa couldn’t clear the follow-up corner, but Kipre lashed well over the bar from 12 yards to let them off the hook.
It was already end-to-end at this point, with Grealish feeding McGinn, making his debut after joining from Hibs, whose left-foot strike was parried away by Walton at full stretch.
But Villa had only themselves to blame four minutes before half-time for the goal that brought Latics level.
An awful backpass from Jedinak was quickly leapt upon by Powell, who won the 50-50 with the advancing goalkeeper and saw the ball roll over the line.
Villa tried to make amends at the beginning of the second half, with Jonathan Kodjia heading over from close range, and that was the signal for Lee Evans - who joined from Sheffield United on the eve of the game - to take over from McManaman to bolster the Wigan midfield.
Latics had another big shout for a penalty turned down when Dunkley appeared to be tripped just inside the box, but it mattered not as goal number two duly arrived on 55 minutes.
Powell did ever so well down the left to make space for himself, and his superb cross was finished off with aplomb by Connolly at the far post.
Unfortunately for Latics, they couldn’t consolidate their lead, and eight minutes later it was 2-2 with Dunkley getting the final touch from a Villa corner leaving Walton helpless.
Jedinak ought to have made up for his error for Wigan’s first goal by putting Villa ahead, only to send a free header wide of the mark from bang in front.
Walton then had to move swiftly across his goal to deny Andre Green from distance, before Latics sent on Windass for his debut in place of the tiring Powell.
The new-boy had an immediate chance to make himself a hero, but could only head over from a wonderful position after being picked out by Evans’ right-wing cross.
As Latics pushed for a winner, they were indebted for the long legs of Kipre to prevent Rushian Hepburn-Murphy having a free run on goal.
Jacobs was the next to be presented with a great opportunity, only to head wide, with James Vaughan taking over from Grigg for the last 10.
With a draw looking on the cards despite the best efforts of both sides, there was to be a final sting in the tale - at the wrong end.
Hourihane did all the donkey work down the left, and his cross was gift-wrapped for Bjarnason to send the Holte End into raptures.