The Cuban government has welcomed a US appeal court decision to retry five Cubans convicted of spying.
The five men had become heroes in Cuba
The men were sentenced four years ago to at least 15 years in jail for spying on US military installations and exiles.
However, the court accepted that the original trial was unfair, because the large presence of Cuban exiles in Miami had created a biased atmosphere.
Cuba has campaigned intensively for the men's release, calling them heroes.
Last month, a United Nations panel also questioned the impartiality of the verdict and called the sentences unduly harsh.
Antonio Guerrero, Fernando Gonzalez, Rene Gonzalez, Gerardo Hernandez and Ramon Labanino were convicted in 2001 of serving in the so-called Wasp Network.
In Havana, National Assembly speaker Ricardo Alarcon hailed the court's ruling.
"It is an important first step that confirms what we have been trying to tell the world about the injustice of this case," he told the Associated Press news agency.
Cuban parliament speaker hailed the release
The defence team were equally as ecstatic.
"It's been a very long seven years for us with a lot of twists and turns and I have to say that there were many times when I doubted the outcome," Hernandez's lawyer, Paul McKenna, told AP.
"But I have new faith in the court of appeals and in the system of law."
The men's families also praised the move.
"It's the first happy news we receive in seven years," said Adriana Perez, the wife of Gerardo Hernandez.
"I jumped, I laughed, I cried," Mirtha Rodriguez, mother of defendant Antonio Guerrero, told AP.
The men have admitted to being spies, but said they were trying to prevent attacks on Cuban President Fidel Castro's government. They said they had not been targeting the US.
Defence lawyers argued that prejudice against Mr Castro and the Cuban government and publicity surrounding the case made it impossible to hold a fair trial in Miami.
The area is home to more than 700,000 people of Cuban descent.
The trial began eight months after federal agents removed shipwreck survivor Elian Gonzalez from his Miami relatives.
The saga had flooded Miami with "waves of public passion" about the relationship between Cuba and the US, the appeals judges said.
The judges wrote: "The reversal of these convictions will be unpopular and even offensive to many citizens.
"However, the court is equally mindful that those same citizens cherish and support the freedoms they enjoy in this country that are unavailable to residents of Cuba."