The Nauru 19 had been charged with offences relating to a protest against the government outside the Nauru parliament in June 2015.
The legal action went through countless stages before the retired judge brought in to hear the case, Geoff Muecke, strongly condemned the Nauru government's actions.
He said that by denying the defendants representation, imposing a blacklist on them, and publicly denouncing and vilifying them and those seeking to assist them, the Nauru government displayed persecutory conduct.
Justice Muecke allowed the permanent stay, calling the government's behaviour a shameful affront to the rule of law.
But the Nauru government has appealed saying the judge's decision was wrong and needs to be corrected.
It said this needs to be done to ensure the community understands that the accused were involved in what the government has always claimed was a riot.