A Peruvian court will issue its verdict on Thursday in the trial of former left-wing president Pedro Castillo, who was impeached and jailed all in the same day in 2022 following a power grab attempt.

Dubbed Peru's first poor president, the former rural schoolteacher and trade unionist, who had never held elected office before winning the presidency, faces up to 34 years in prison if convicted of trying to disband Congress and rule by decree on December 7, 2022.

The verdict in his case comes a day after another left-wing ex-president, Martin Vizcarra, was sentenced to 14 years' imprisonment for bribe-taking while serving as a regional governor.

Two other former presidents are already behind bars at a special penitentiary for ex-leaders: Ollanta Humala (2011-2016) and Alejandro Toledo (2001-2006).

Castillo, 56, took the highly controversial decision to dissolve Congress after multiple attempts by the opposition-dominated parliament to impeach him for alleged corruption.

His stunt failed spectacularly, however, with members of his own government siding against him.

Castillo was impeached and arrested on charges of rebellion, abuse of authority and serious disturbance of the public order within a matter of hours.

He has been in preventive custody ever since, alongside Humala and Toledo.

His nine-month trial took a dramatic turn earlier this month when his former prime minister Betssy Chavez, also put in the dock, was given asylum by the Mexican embassy.

Peru broke off diplomatic ties with Mexico over what it called an "unfriendly act" and has not ruled out storming the Mexican embassy to arrest Chavez.

Castillo's arrest and impeachment sparked mass protests in 2022 among his working-class rural base.

The protests were harshly repressed, leading to at least 50 deaths.

His deeply unpopular successor, former vice-president Dina Boluarte, led the country for a tumultuous 22 months marked by a deep security crisis before also being impeached in October.