Jason Kenny gave Great Britain its 12th cycling medal of the Olympic Games with his gold medal ride in the men's keirin, but his victory almost never came to be when the judge fired a gun signalling a violation of the rules during the final.
In the keirin, a derny driver brings the six men up to speed and then pulls off the track to let the powerful sprinters battle for the next 600m. One important caveat - the riders cannot pass the derny before it pulls off the track or they will be disqualified.
Kenny attacked with Azizulhasni Awang (Malaysia) heading into turn three just as the derny began its exit and immediately the gun went off.
Iain Dyer, Great Britain’s head coach, dashed to the judges.
"Normally if they fire the gun and stop the race riders get DQ'd, game over," Dyer said according to the Telegraph.
In the tense minutes that followed, it emerged that the Olympic Games velodrome had not been equipped with a camera at the point of the derny's exit, and lacking a photo finish of the moment showing that Kenny's front tyre overlapped the derny's rear tyre, the judges were convinced the move was too close to call.
It also turned out that two British Cycling performance analysts were in the crowd filming at that moment, and provided a video showing how close it was.
"I had a little look on our video straight away and it looked really, really close. It wasn't obvious," Dyer said. "So I asked the commissaire to show me their footage and what they showed me was a head-on shot. They've got a camera in turn three looking straight down the back straight. So I offered our footage as they didn't have a camera."
The chief commissaire, German Alex Donike, opted to re-start the race with all of the riders on the line.
"They [the commissaires] didn't have the evidence to chuck him out but they would have been under pressure, having stopped the race, to put someone out," Dyer said. "There was clearly doubt. And I think they achieved the fairest outcome without a camera on that line. I would expect a camera there to be honest."
Immediately after the decision was announced, social media was flooded with allegations of favouritism or cowardice by the judges, but the same kind of infraction occurred with German Joachim Eilers on the re-run of the race. Once again, the video from the British analysts saved the day and all six competed in the final, successful running of the keirin gold medal round.
Kenny won gold over Matthijs Buchli (Netherlands) and Awang.
Poland's Damian Zielinski, who finished outside the medals, objected to the ruling saying it was clear that Kenny and Awang overtook the derny. "They didn't want to retake the medals from the guys," he said. "I think normally, they should be disqualified, but you cannot argue with the judges."
Cyclingnews reached out to the UCI immediately after the judges' decision, but received no reply.