It came as no surprise that the Spanish oil company Repsol SA would sue the Republic of Argentina for seizing its majority stake in the Argentine energy company YPF SA in 2012. What’s more intriguing is that lawyers for YPF shareholders brought a class action against both Repsol and YPF, alleging that the companies misled them by failing to warn them about the possibility that YPF would get nationalized.

That class action met a quick demise on Thursday, when U.S. District Judge Shira Scheindlin dismissed it in a stinging 44-page decision. She ruled that plaintiffs counsel at Robbins Geller Rudman & Dowd waited too long to file the case, and that in any event there were no misrepresentations on Repsol and YPF’s part.

The dismissal is with prejudice, meaning Robbins Geller can’t file an amended complaint with new theories. Scheindlin also went the extra step of dismissing YPF and Repsol executives from the case, even though they hadn’t filed motions to dismiss—or even appeared in court, for that matter. YPF and Repsol’s arguments for dismissal “apply with equal force” to the individual executives, Scheindlin ruled.

Latham & Watkins attorneys, including Miles Ruthberg, James Brandt and Chris Harris, represented Repsol. Thomas Hall of Chadbourne & Parke represented YPF.

Repsol acquired a controlling interest in YPF back in 1999. The Argentine government nationalized YPF in April 2012, seizing most of Repsol’s stake. The Argentine government alleged that expropriation was necessary because Repsol was underinvesting in YPF’s lucrative oil and gas assets.

Investors didn’t react well to the expropriation, sending YPF’s stock price tumbling 32 percent the next day. Robbins Geller brought suit, alleging that Repsol and YPF had painted an overly rosy pictures of YPF’s future prior to the government’s takeover. The firm alleged that YPF, while it was under Repsol’s control, should have disclosed that it was underinvesting in Argentina’s oil fields, making the government more likely to expropriate. Shareholders also should have been informed about the negative impact expropriation would have on stock price. YPF was named as a defendant because it was the one that bore the duty of honesty to YPF shareholders, and Repsol was named as a defendant since it was controlling YPF at the time.

Siding with Latham and Chadbourne, Scheindlin dismissed those theories in Thursday’s decision. She ruled that the investing public was well aware that nationalization would impact YPF’s stock price, so Repsol and YPF had no duty to disclose that fact. “Many of these alleged omissions were either fully disclosed or matters of public knowledge,” she wrote.

“We think it’s a well-reasoned decision that came to the right result,” said Chadbourne’s Hall, who represented YPF.

The ruling comes just a few days before Argentina is expected to announce a $5 billion deal to compensate Repsol for the expropriation. Reuters broke news of the near-complete deal on Thursday.