Brazilian lawmakers voted on Wednesday to shorten the prison sentence of former right-wing President Jair Bolsonaro, although the bill is likely to face resistance from senators, the Supreme Court and leftist President Luiz Inacio Lula da Silva.

In a tense session that descended into chaos ahead of a vote in the early hours of Wednesday morning, Brazil’s lower house approved a bill that could reduce Bolsonaro’s prison term from 27 years to just over two, according to its sponsor.

Last month, Bolsonaro began serving his sentence for plotting a coup against Lula after losing the 2022 election.

Wednesday’s bill, approved in a 291-148 vote, reduces sentences for those convicted for their roles in a January 2023 riot, when Bolsonaro supporters invaded and ransacked the presidential palace, Supreme Court and Congress.

The vote comes days after the ex-president’s eldest son, Senator Flavio Bolsonaro, announced a presidential bid and began talks with a group of centrist parties known for their influence in Congress.

Senator Bolsonaro told journalists that the “price” of his candidacy was his father’s freedom, before walking back those comments and calling his candidacy “irreversible.”

A preliminary version of the bill put forward by opposition right-wing lawmakers would have pardoned those involved in “political demonstrations” after Lula’s election, but the bill’s sponsor Paulinho da Força ruled out granting them full amnesty.

“There is no possibility of amnesty,” he said. “We spoke with all the parties, and the only viable project to pacify Brazil is the reduction of sentences.”

About 2,000 people were arrested over the Brasilia attack, which drew comparisons to the January 2021 attack on the U.S. Capitol in Washington. Many have been convicted by the Supreme Court of attempting a coup, among other crimes.

The bill will need to pass a Senate committee and then a floor vote before it would go to Lula for a signature.

BILL FACES PRESIDENTIAL HURDLE

A government minister, speaking on condition of anonymity, said it will be difficult to stop the bill from passing the Senate but Lula is expected to veto it — leaving Congress with the burden of trying to overturn a veto.

Lula’s Institutional Relations Minister Gleisi Hoffmann called the lower house vote a “serious setback.” She said the bill weakened laws that defend democracy and challenged the Federal Supreme Court’s rulings in the coup-plotters’ trials, which have not concluded yet.

“This is the result of political interests between the Bolsonaro family and opposition leaders,” Hoffmann said.

Chaos erupted in the chamber ahead of the vote, after lower house President Hugo Motta announced a floor vote on the bill, along with other votes to strip the titles of several lawmakers in the chamber.

One of those lawmakers, Glauber Braga of Socialism and Liberty Party, occupied Motta’s chair in protest, prompting the chamber’s president to have him forcibly removed by police.

Reporters said they were removed from the plenary during the commotion, prompting three journalists’ associations to condemn in a joint statement what they called “intimidation tactics” against the press.