Papua New Guinea‘s (PNG) Prime Minister Peter O’Neill has formally resigned, easing a months-long political crisis and calling a major French and US-backed gas deal into doubt.

Facing a vote of no confidence he looked sure to lose, O’Neill on Wednesday told parliament that he had tendered his letter of resignation to the country’s governor general.

A parliamentary vote on a new prime minister is expected to take place in the coming days.

O’Neill had led the country since 2011 but had been criticised for endemic corruption and chronic underdevelopment.

Powerful regional politicians had baulked at his recent $13bn deal with Total and ExxonMobil to extract, pipe and ship liquefied natural gas (LNG) overseas.

Finance Minister James Marape was the first senior cabinet official to resign in protest, saying the money would not go to ordinary Papua New Guineans, local firms or the regions.

A similar deal in the last decade has failed to bring wealth to a country where around 70 percent of people do not have access to reliable electricity.

Reshuffle on the cards?

O’Neill had earlier promised to resign but failed to do so and took court action in a bid to cling to power.

That prompted angry scenes in parliament on Tuesday, including physical confrontations between O’Niell’s supporters and opponents trying to remove him and the speaker of parliament.

After announcing his resignation on Wednesday, O’Neill touted his achievements in office, including hosting the 2018 APEC summit, a vast undertaking for a developing country with limited central government capacity.

“We have always been known for the wrong reasons,” the veteran politician said in a valedictory speech.

Experts said that his departure could see an end to big-ticket infrastructure projects that many believe have benefited only Port Moresby and the country’s connected elite.

“O’Neill’s departure has the potential for a wholesale shift in the policy direction taken by PNG’s government,” said Jonathan Ritchie of Melbourne’s Deakin University.

“But the suspicion of at least some informed Papua New Guinean observers is that it will result only in the rearranging of the deck chairs,” he wrote in the face of O’Neill’s departure.

“A reshuffling of the cards that will lead to another privileged insider, another member of PNG’s political class, taking over the PM’s role from the mostly unlamented O’Neill.”