Dr Stella Nyanzi collapsed at the International War Crimes Division of the High Court in Kampala, Uganda, on Thursday minutes after the judge ordered for her release from Luzira Prison where she has been for months.
Dr Nyanzi was last year convicted and sentenced to 18 months for harassing President Yoweri Museveni.
However, she appealed against the conviction and sentence, citing unfairness and that the trial court erred in law.
On Thursday, Justice Henry Peter Adonyo who heard her appeal ordered for her “immediate release” from prison.
The judge noted that Buganda Road trial magistrate, Gladys Kamasanyu, had no jurisdiction to convict Dr Nyanzi of cyber harassment.
In addition, Justice Adonyo said no evidence was adduced by the prosecution showing the location -- of the device -- where the offence was committed; either in Uganda or out of the country.
“Prosecution did not as well ascertain the kind of device which was used to send as the digital prints were not presented before Buganda Road,” the judge observed.
The court also observed that Dr Nyanzi and her lawyers were not allowed enough time to prepare their defence thus amounting to unfairness.
The first prosecution witness did not provide a forensic report on his findings indicating which mobile data was used, after he asserted that Dr Nyanzi might have used a phone.
The judge also said that in criminal offences, it is the duty of court to ensure that defense witnesses appear by providing the defendant the favourable avenues like issuing arrest warrants for defence witnesses who are not compliant. The magistrate did not do this.
The judge’s orders forced the fully packed court to explode in excitement as Dr Nyanzi’s supporters, friends and relatives jostled to congratulate her.
She collapsed as she was being assisted to go sign her release papers.
Prison warders were later seen carrying her to a waiting prison car registration number UG 0172U.
Dr Nyanzi was in August 2019 handed an 18-month prison sentence for publishing a verse that Magistrate Kamasanyu said should never have been put in the public domain, describing it as "obscene" and "indecent" including suggestions which "could only be made by an immoral person."
Dr Nyanzi has already served nine months in Luzira Women's Prison.