A man in Moscow’s Red Square holds a poster in support of freeing Ukrainian military pilot Lt. Nadiya Savchenko. (Yuri Kochetkov/European Pressphoto Agency)

A Russian court on Tuesday sentenced a Ukrainian helicopter navigator to 22 years in prison in a contentious murder trial that has drawn sharp condemnation from the West.

A judge convicted Lt. Nadiya Savchenko, 34, of directing mortar fire that killed two Russian journalists during pitched fighting in eastern Ukraine in 2014. Savchenko said that she was innocent and that pro-Russian separatists abducted her in Ukraine before crossing the border and delivering her to Russian police.

Shortly after the verdict was delivered, Ukrainian President Petro Poroshenko said he would not recognize the decision in the proceeding, which he called a “shameful show trial.”

He also said he would demand Savchenko’s return to Ukraine, ­offering a trade in exchange for her freedom. “I am ready to hand over two Russian servicemen detained in our territory for their participation in the armed aggression against Ukraine,” he said in a statement, referring to two alleged Russian servicemen arrested for fighting alongside separatists in Ukraine last May. They are being tried on terrorism charges.

Savchenko’s trial was a cause celebre in Ukraine, where she was elected a member of parliament while in Russian custody and awarded the title Hero of Ukraine. She was equally demonized in the Russian news media as a member of a far-right para­military battalion who was driven by hatred for ethnic Russian speakers.

As the judge delivered the verdict, Savchenko began singing the Ukrainian national anthem, forcing a recess. Few expected leniency when the sentencing resumed.

“For us it isn’t really important what figures are in the verdict, whether it was 25 or 30 or 22 years,” said Oleksiy Ryabchyn, a member of Ukraine’s parliament who joined fellow lawmakers in traveling to the border town of Donetsk, Russia, for the verdict. “It was just the end of the judicial stage for releasing Savchenko. Now the political stage begins.”

The office of Russia’s chief prosecutor said it was satisfied with the decision “given the gravity of the acts committed by her.” Prosecutors in the case had asked for 23 years in prison. Savchenko was also fined 30,000 rubles, or about $440, for ­illegally crossing the border from Ukraine into Russia.

“The conviction and sentencing of Nadiya Savchenko to 22 years’ imprisonment show a blatant disregard for the principles of justice,” State Department spokesman John Kirby said in Washington. “We reiterate our call on Russia to immediately release Nadiya Savchenko and other unlawfully detained persons.”

U.S. officials urged Russia to release Savchenko under the Minsk accord, which was signed by Russia, Ukraine, France and Germany and provides a road map to end the conflict in eastern Ukraine. The accord stipulates the release of all hostages by all parties to the conflict. Russia says the pact does not apply to Savchenko because of the charges she faced.

Russian officials had repeatedly said there could be no discussion over Savchenko’s release until the court delivered a verdict. Ukraine has demanded sanctions against Russian law enforcement and judicial officials responsible for Savchenko’s detainment.

Read more:

Reports: Russian court poised to convict Ukraine’s ‘Joan of Arc’ in deaths of journalists

Clinton quietly expresses support for Ukrainian pilot jailed by Russia

Watch: Ukrainian pilot guilty of murder