IN 2013 – six years before Alan Bates won his big civil case – Scottish prosecutors missed a golden opportunity to act decisively on concerns that the Post Office’s computer evidence may not be reliable.

Mystifyingly, almost nobody in Scottish politics or the media seems interested in this missed opportunity, or why it was missed. After a promising start, Holyrood and much of the press has abandoned any effort to get to the bottom of Scottish aspects of the scandal, exploring the distinctive ways in which the Post Office’s toxic culture of incompetence, cover-up and suspicion resulted in scores of Scottish postmasters in court, wrongly accused of having their hands in the till.

But last week, we learned a lot more about the critical Scottish meeting which deferred a proper reckoning with the corporation’s many lies and evasions about the reliability of its accounting software, resulting in hundreds of subpostmasters being wrongly prosecuted or pursued for civil debts that they did not owe for money that they had not taken.

First, some context. In England and Wales, the Post Office had the legal authority to run its own criminal cases. But in Scotland, it was just a “specialist reporting agency” to the Crown Office. If it wanted a Scottish subpostmaster prosecuted for a shortfall, it needed to persuade the procurator fiscal that it had a corroborated case of theft, embezzlement or fraud.

READ MORE: New poll finds support for monarchy in Scotland falling rapidly

Back in January, the Lord Advocate stressed that “right up till 2019”, the Post Office “continued to assert that the Horizon system was sound” and that the Crown Office was “entitled to take those assurances at face value”.

Scottish prosecutors, the Lord Advocate suggested, “would not have known, nor suspected” that the Post Office “might not have revealed the true extent of the Horizon problems” until after Mr Bates’s victory in the civil courts.

The problem with this suggestion is that we now know that some Scottish prosecutors did, in fact, suspect that Horizon might not be reliable six years before Mr Justice Fraser’s judgment put the matter beyond doubt.

Let’s go back in time. 2013 was a rough year for the Post Office, trying to contain what would become a national scandal a decade later. Public criticism of the Horizon system was increasing.

Forensic accountants Second Sight had begun to produce material confirming that the Fujitsu accounting software was affected by known design failures and bugs which could generate shortfalls in postmasters’ branch accounts without any money being dishonestly taken.

The National: Protestors outside the Post Office Horizon IT inquiry. Picture: PA

In the summer of 2013, its new lawyers – Cartwright King – discovered that the Post Office’s star witness in Horizon prosecutions – Fujitsu engineer Gareth Jenkins – had known about these bugs, but worked up witness statements with Post Office lawyers in which he’d sworn blind to “the robustness and integrity of Horizon in express terms”.

In-house barrister Simon Clarke told his clients not only that Jenkins was a “tainted witness”, but that the Post Office had violated its duties as a prosecutor by failing to disclose all this information to the people it prosecuted, many of whom insisted that Horizon was responsible for the phantom money they were accused of stealing.

And worse, Clarke pointed out that this duty of disclosure doesn’t end on conviction. Eventually, they’d have to come clean to subpostmasters like Seema Misra, jailed while pregnant with her second child, in great part on Jenkins’s potentially perjured evidence.

And from Scotland – more bad tidings. Someone in the Crown Office and Procurator Fiscal Service clearly took Private Eye or Computer Weekly seriously, because they also suddenly had their doubts about whether the Horizon printouts could be trusted. A meeting was organised to discuss what to do with the Scottish cases given these “concerns about the safety of prosecuting using Horizon data”.

READ MORE: Humza Yousaf congratulates Sadiq Khan on London mayor election win

We now know the true position was even starker than that. Going into this meeting in Edinburgh, Crown Office officials had “provisionally concluded that all Post Office prosecutions in Scotland should be terminated”. That’s right. Every single case. In 2013.

Post Office lawyers characteristically focused on the PR implications of this, expressing immediate concerns about “adverse publicity” and a “considerable public relations storm” across the UK if anyone found out Scottish prosecutors wouldn’t rely on Horizon.

So in September 2013, a troop of Post Office lawyers took a trip to Edinburgh. We’ve known about this meeting since it was first highlighted at the inquiry late last year, but until this week had only patchy information on who was present and what was discussed.

On the face of it, the goal of this mission was to change the Crown Office’s mind. The delegation included Jarnail Singh – the Post Office’s head of criminal law – and the self-same Simon Clarke of Cartwright King, who knew about the software bugs, who knew about Gareth Jenkins’s potential perjury, who knew the party line that Horizon is “entirely robust” was not true.

Last week, the identities of the Crown Office officials in the room were finally revealed. According to documents obtained by the public inquiry, they were fiscals Paul Beaton and Paul Miele. On the day, Miele seems to have taken the lead, telling his Post Office counterparts that “his role was to formulate a policy recommendation and to forward that to the Procurator Fiscal for his decision as to how Post Office cases were to be dealt with”.

The National: Post Office

Miele seems to have set out their starting position in no uncertain terms – “that all such cases should be terminated” because the Post Office was “unable to provide that Horizon was wholly reliable”. The PF would be unable to prosecute any case unless an expert witness could be called, on oath, and answer with an “unqualified yes” when asked if the accounting system was reliable. Anything other than this wouldn’t do, Miele is reported to have said.

A few months earlier, Gareth Jenkins would have been obvious casting for this expert role. But given Clarke’s knowledge of the collapse of Jenkins’s credibility and the exaggerated claims about Horizon’s reliability, you might have expected a candid investigator to tell Scottish prosecutors about these compromising facts, but this kind of admission was hardly likely to douse Crown Office doubts.

So we now know – they didn’t tell them. The note of the meeting contains the following incriminating line. It explains that Simon Clarke gave Scottish prosecutors “a broad overview of the Horizon Online difficulties” but “absent any direct or indirect reference to the role of Gareth Jenkins or Fujitsu”.

Clarke is due to testify next week, but counsel for the inquiry Jason Beer KC tested Jarnail Singh’s recollection of this critical moment on Friday. As usual, Beer was asking all the right questions. “Why did you not disclose that there had been a problem with Gareth Jenkins’s evidence in earlier prosecutions?” he asked.

READ MORE: Andrew Neil in furious outburst at The National over SNP cartoon

“Did you tell the Procurator Fiscal why the Post Office had to instruct new experts? What was wrong with the old one?” Beer demanded. “Was there a desire to keep that secret?”

“Not on my part,” came Singh’s characteristically limp response – keen to present himself as a pitiable postbox of a man with no agency, ideas or understanding of his own.

Frustratingly, these partial representations seemed to do the trick, persuading the two Procurators Fiscal present to dump the policy of bringing all Horizon prosecutions to a screeching halt. Miele left the meeting, confirming that “his recommendation would be that each case be reviewed separately and a decision taken on the facts of individual cases”, on the promise of a new expert witness, burying systemic problems with Horizon in individual decision-making, and indefinitely deferring the “considerable public relations storm” Cartwright King was so concerned about.

As the Post Office minutes note with an air of quiet triumph, this amounted to a “complete reversal of the PF’s original position”. But it was a reversal accomplished by an astonishing lack of candour and what look very much like lies of omission. In retrospect, what a mistake, what an opportunity missed.