Navartia The S-80, clearly computer-generated.

One of Spain’s largest defense splurges may also be one of its most embarrassing. After spending nearly one-third of a $3 billion budget to build four of the world’s most advanced submarines, the project’s engineers have run into a problem: the submarines are so heavy that they would sink to the bottom of the ocean.

Miscalculations by engineers at Navantia, the construction company contracted to build the S-80 submarine fleet, have produced submarines that are each as much as 100 tonnes (110 US tonnes) too heavy. The excess weight sounds paltry compared to the 2,000-plus tonnes (2,205 US tonnes) that each submarine weighs, but it’s more than enough to send the submarines straight to the ocean’s floor.

Given the mistake, Spain is going to have to choose between two costly fixes: slimming the submarines down, or elongating them to compensate for the extra fat. All signs point to the latter, which will be anything but a breeze—adding length will still require redesigning the entire vessel. And more money on top of the $680 million already spent.

Spain’s defense ministry, the government arm responsible for overseeing the project, has yet to say how much the setback will cost in both time and money. But Navantia has already estimated that its mistake will set the project back at least one or, more likely, two years. And the Spanish edition of European news site The Local reported that each additional meter added to the S-80s, already 71 meters in length, will cost over $9 million.

It’s a costly mistake on many fronts. The state-of-the-art submarines were meant to be the first entirely Spanish-designed and built. Incompetence is likely going to cost the country at least some of the glory. Electric Boat, a subsidiary of US-based technology firm General Dynamics, has already evaluated the project and could be hired as a consultant to save the job.

Another bailout for Spain. This is getting all too familiar.