ISTANBUL (AP) — A court convicted the president of the Turkish Medical Association on Wednesday of disseminating “terror organization propaganda” following a trial that human rights groups had denounced as an attempt to silence government critics.

The court in Istanbul sentenced Dr. Sebnem Korur Fincanci to nearly three years in prison but also ruled to release her from pre-trial detention while she appeals the verdict.

Fincanci, 63, was arrested in October and charged with engaging in propaganda on behalf of the banned Kurdistan Workers’ Party, or PKK. The arrest followed a media interview in which she called for an independent investigation into allegations that the Turkish military used chemical weapons against Kurdish militants in northern Iraq.

Fincanci is the latest activist to be convicted under Turkey’s broad anti-terrorism laws. A forensic expert, she has spent much of her career documenting torture and ill-treatment, and has served as president of the Human Rights Foundation of Turkey.

During her trial, Fincanci rejected accusations that she engaged in propaganda during the interview, arguing that she gave a professional opinion.

The charges stemmed from an interview she gave to the pro-Kurdish Medya Haber TV outlet and commented on a video purporting to show the use of chemical weapons. She suggested that a toxic gas may have been released but also called for an “effective investigation.”

Turkish officials strongly denied allegations that the country used chemical weapons, insisting its military doesn’t have such weapons in its inventory. The PKK has led an armed insurgency against the Turkish state since 1984. The group is considered a terrorist organization in Turkey, Europe and the United States.

Her comments caused a backlash with Turkish President Recep Tayyip Erdogan accusing her of slandering Turkey’s armed forces and of insulting her country “by speaking the language of the terrorist organization.”

He vowed to introduce measures to clear the Turkish Medical Association and other professional organizations of “supporters of the terrorist organization.” In October, the justice minister said they were working on new regulations.

Devlet Bahceli, the leader of a nationalist party that is allied with Erdogan’s ruling party, went further and demanded that she be stripped of her Turkish citizenship and the association shut down.

The association, which has around 110,000 members across Turkey, had drawn the ire of government officials for questioning government data and criticizing some measures imposed during the Covid-19 pandemic.

In her final trial statements, Fincanci said the association was the actual target of the investigation, according to the Dokuz8haber website, which monitored the trial. She said freedom of expression and science were being undermined.

A European Union delegation observed the trial on Wednesday, along with rights groups and supporters, in a packed courtroom.

Ahead of the hearing, Dr. Ole Johan Bakke of the Standing Committee of European Doctors, said the group was “deeply concerned about the continuous harassment of the Turkish Medical Association from the Turkish government and authorities.”

The World Medical Association has described the case against Fincanci as “unfounded, unlawful and unacceptable” and had called for her immediate acquittal.

The Istanbul court sentenced to two years, eight months and 15 days in prison. She is expected to appeal the verdict.

Other leading civil society figures and dozens of journalists are imprisoned in Turkey. Terror propaganda laws have also been used to crackdown on pro-Kurdish politicians and activists.

Fraser reported from Ankara, Turkey. Zeynep Bilginsoy contributed from Istanbul.