Following successive failed negotiations since April, Spain’s acting prime minister Pedro Sánchez appears to have brokered a deal to form a government. On Tuesday, the leader of the Socialist Party of Spain (PSOE) will test his emerging coalition in parliament as he tries to secure the official mandate to form a government.

Sanchez will need 176 votes in a 350-seat parliament in a vote to be held on Thursday. PSOE may need fewer votes if a number of MPs abstain.

The Socialists have 123 MPs but PSOE appears close to securing the backing of the anti-austerity party Unidas Podemos, with 42 MPs. The two parties have deep differences on how to deal with the Catalan crisis, with Podemos insisting on a referendum. If that deal is sealed, PSOE may also hope for support from the Basque National Party (six) and members of the so-called Mixed Group of regional parties, avoiding a politically toxic dependence on the Catalan Republican Left (14 seats).

A coalition cabinet would require PSOE giving Podemos ministerial portfolios, which is unprecedented for the far-left. On Monday, the leader of Podemos Pablo Inglesias made clear he would not participate in a future cabinet, paving the way for a possible compromise.

Podemos appear prepared not to take portfolios that will present the coalition with constitutional dilemmas – internal affairs, foreign affairs, justice, and defence – but they would demand influence over economic policy and a deputy prime ministerial position.

Testing this hypothetical majority on Monday, Sanchez talked about a government that would take on the challenge of unemployment and precarious work, especially in the context of a digital revolution, while preparing Spain for climate emergency.

Critically, he avoided any discussion about Catalonia, a fact raised by the conservative Popular Party (PP), to the center-right Ciudadanos, the far-right Vox, as well as the Catalan Republican Left (ERC), Navarra Suma, the Canaries Coalition, Compromís, the Regionalist Party of Cantabria and even the Basque radical-left Bildu.