Today's announcement ends a convoluted legal saga that started with an undercover investigation nearly five years ago.
In September 2009, police were worried the Red Devils in Nelson were engaged in serious criminal offending and had forged links with local Hell's Angels.
A surveillance operation started but police needed more evidence to smash the gang, so in November that year planted two undercover officers with the Red Devils.
An embedded officer hit a roadblock when one Red Devils member, the late Mike Tulouna, told him members wanted assurances he was not an undercover police officer.
Soon after this, the undercover officer known as Mr 'Wilson' involved Tulouna in an illegal paua selling operation.
But rumours continued spreading of two "agents" lurking around Motueka.
"In order to protect the true identities of Mr 'Wilson' and Ms 'Robinson' and to ensure that Operation Holy could continue to provide the police with evidence against the defendants, the false warrant and prosecution scenario was created," Justice Collins said.
A ruse involved police placing ostensibly stolen laptops, ammunition and equipment linked to cannabis offending in a storage unit.
Police then prepared a fake search warrant. Where a court registrar or judicial officer would usually sign the warrant, a cop signed instead.
In May 2010, police raided the unit, arrested Mr 'Wilson' and charged him with a drug offence.
Two days after the arrest, top detectives met the Chief District Court Judge. They believed the judge approved of the false warrant and prosecution.
Mr 'Wilson' then made multiple court appearances, but also failed to turn up to court several times, in ploys designed to boost his credibility with the Red Devils.
Charges against him were withdrawn in March 2011 when Operation Holy and the older surveillance operation ended.
The following year, Justice Simon France ordered a stay of criminal charges and 21 Red Devils members or associates walked free.
Justice France said the false warrant and prosecution scenario was an abuse of the Court's process and "a fraud ... committed on the courts".
Police Association president Greg O'Connor slammed the decision and called it a "slap in the face" for an officer who'd risked his life for a a year to catch the Red Devils.
The Court of Appeal overturned Justice France's stay of criminal charges a year later, saying police misconduct was "grave" but putting the Red Devils on trial would not mean the court condoned the police misconduct.
But the legal see-sawing continued and more evidence was presented to Justice Collins.
"Senior police officers devised the false warrant and prosecution scenario because they believed the ends justified their means," Justice Collins said in May.
"Had a private prosecutor engaged in similar tactics he or she could expect to face the full wrath of the criminal justice system."
All charges against Red Devils dated after June 1, 2010 were thrown out.
Justice Collins said any alternative would seriously undermine public confidence in the criminal justice system.