MADRID — Spanish Prime Minister Pedro Sánchez announced Friday a snap general election for late April, after Catalan separatists withdrew their support for his minority government.

The announcement marks the latest escalation in a long-simmering political crisis over Catalan independence that has rocked Madrid even before Sánchez, a socialist, took power in June 2018. It also presents a major challenge to one of Europe’s last remaining center-left governments in an atmosphere of right-wing ascendance across the continent.

For Sánchez, the move is a concession of sorts. Over the weekend, tens of thousands of Spaniards protested in Madrid, insisting that Sánchez call elections after planning to appoint an intermediary for talks between the Spanish government and the Catalan government, a step outside the parameters of the Spanish constitution. The protests were organized by Spain’s major right-wing parties.

Sánchez was elected with the help of Catalan separatist parties, factions that were irate over the trial of 12 Catalan secessionist leaders that began on Tuesday. The 12 played a role in staging an illegal Catalan independence referendum in October 2017 and stand accused of sedition and the misuse of public funds. Nine of the 12 also are accused of “rebellion.”

The trial marks a watershed moment in the political history of modern Spain, which transitioned back to democracy following the death of dictator Francisco Franco in 1975. Within the European Union, the Catalan trial is an unprecedented foray into political theater, with a central government cracking down sharply on a regional insurrection.

The accused Catalans see the trial as a case of politics trumping justice. “This is a political trial, and I refuse to answer my accusers,” said Oriol Junqueras, Catalonia’s former vice president and one of the 12 accused. “I am a political prisoner, and I am on trial for my ideas.”

Madrid, however, has characterized Catalonia’s approach to independence as extrajudicial.

“They wanted to hold a referendum, but they didn’t have permission,” Irene Lozano, secretary of state for global Spain, said in a Thursday interview with Sky News.

“I normally use the metaphor of sex. Sex is not forbidden like voting is not forbidden. But you cannot do it forcefully. You have to have permission; otherwise, it is rape. It’s the same with democracy. It’s not just saying we always can vote. You have to apply the law in a democracy.”

Friday’s call for elections followed the defeat of the Sánchez government’s 2019 budget in the Spanish parliament on Wednesday. A day after the trial began, the Catalan separatists as expected did not support the plan.

Elsa Artadi, a spokeswoman for the Catalan government, criticized what she called Sánchez’s “failure and lack of courage” for choosing appearances instead of facing the Catalan question with “determination.”

“Spain will be ungovernable until the political conflict with Catalonia is resolved. The problem with Catalonia is a problem of state. The problem with Catalonia impedes the state from developing a project for the future,” she said.

Sánchez, however, accused the conservative opposition of paralyzing his government’s vision for a fairer Spain.

It is “an opposition which hasn’t listened to reason,” he said Friday in a televised address to the nation. “An opposition that is far removed from the parameters of common sense and the moderation that is demanded of a leader of the opposition.”

The conservative Popular Party holds the largest single share of seats in the Spanish parliament: 134 of 350. Sánchez’s party, by contrast, holds only 84 seats in parliament.

McAuley reported from Paris.

Read more