MADRID (Reuters) - Spain’s Supreme Court said on Thursday it had told the European Parliament that Catalan separatist leader Oriol Junqueras will not be released from prison to claim his seat as an MEP despite a EU court ruling that he was entitled to immunity.

Junqueras was sentenced to 13 years in prison in October over his role in Catalonia’s failed bid for secession in 2017. He was elected a member of the European Parliament while in prison awaiting the verdict and was unable to take up his seat.

His case got a boost last month after the European Union’s highest court ruled that the Catalan leader was entitled to immunity as an MEP. The final say on how to comply with the verdict, however, was left to Spain’s Supreme Court.

The court ruled that the sentencing of Junqueras barred him from enjoying immunity as an MEP. It rejected allowing Junqueras to travel to the European Parliament and any notion of annulling his sentence.

“There are no grounds to grant his freedom,” the court wrote in its ruling.

Junqueras’ Esquerra Republicana de Catalunya (ERC) party reacted with disappointment to what they described as “Spanish injustice”, accusing the court of violating Junqueras’ rights and disobeying international institutions.

Pere Aragones, a top ERC official and vice-president of the Catalan government, described the ruling as an “absolute scandal” and pledged to fight the decision at the national and European judicial levels.

“We will exhaust all viable avenues open to us that we have in our reach,” he told a news conference.