The Second Avenue Subway—or lack thereof—has been the laughingstock of New York for nearly 100 years: the critical project that the most ambitious city in the world never could build.

Today, New Year’s Eve, if all goes well, Gotham’s mythical subway will become reality. As he prepares to take the inaugural ride on the train route, New York Governor Andrew Cuomo is trying to transform the subway’s saga from a symbol of infrastructure failure into one of infrastructure success.

But New Year's Eve is always more depressing than it is uplifting, and the Second Avenue Subway's minutes-to-midnight debut is still more about our failures than triumphs. Figuring out what went wrong could help the country build more stuff right.

***

Back in September 1929, New York’s real-estate investors thought they were pretty smart. Brokers told The New York Times that “every Second Avenue owner approached by them the day of the announcement of the proposed Second Avenue subway last week either withdrew his property from the market or raised his price about 50 percent.”

The subway—already promised off and on for nearly a decade—was finally coming. Stretching from the East Bronx to Brooklyn, it would mean higher property values for owners in between. In the next month, a dozen properties along the route would change hands, as speculators sought to control entire tenement blocks.

What happened after that was, well, nothing. In 1930, the city held public hearings on the planned route. In 1931, New York started preliminary construction work—but the work was so preliminary that neighborhood businesses formed a “joint civic committee” to force the city into making specific construction plans, including realistic cost estimates. By 1934, one resident warned that it probably wasn't a good idea to tear down the elevated transit line “until the city provides us with that Second Avenue Subway.” (The city tore it down anyway, six years later.)

The next year, in 1935, the subway project collapsed, not with a grand announcement but with some whimpering. The city's transportation chief told a Brooklyn audience that because the Depression had hurt property values even as it had forced the city to increase debt, “further postponement… was almost inevitable.” Forty years later, the state, which had recently taken control of the subways from the city, re-started the project. But a new fiscal crisis ended that attempt, too.

***

The early failures of the Second Avenue Subway were two-fold. First, until the late 1970s, the city had no financial checks and balances. New York's approach to its subways and everything else was simple and short-term: Gotham funded projects on a day-to-day basis out of one big pot of money, without consideration for priorities or long-term costs. Then, when it ran out of money, it stopped. (Though private-sector monopolies ran the first subways, and not very well, the city paid for their construction.)

Second, the city suffered from national trends, and its own lack of vision. By mid-century, federal money went toward suburban highways, to help people leave outdated, dirty cities. The federal money that went to cities was for social spending on public housing and welfare, not infrastructure. The city spent its own transit money on good union jobs and on trying to keep fares flat, rather than investing in physical assets.

The good news is that we've admitted both of those problems, if not exactly solved them. New York today has excellent financial checks and balances, including a well-scrutinized annual budget and a 10-year budget for major capital projects. A state-run public corporation, the Metropolitan Transportation Authority, runs the transit system separately from both the city and state budgets. This structure theoretically insulates money that the city needs for transit infrastructure from the relentless pressures of day-to-day government spending.

And though other cities continue to struggle, New York has thrived. Even the more obtuse public officials dimly understand the need for infrastructure investment to support a record, and growing, population. The city is also so flush with tax revenues that it can spend more than $9.8 billion on worker pensions annually and $7.5 billion on health and welfare for the poor, and still have a little money left for infrastructure.

***

A decade ago, then, New York was in a healthy enough position to re-start that Second Avenue Subway, to public skepticism that it could ever complete the project. We've made enough progress since then so that just before Christmas this year, Gov. Cuomo could say that the new subway would “remind New Yorkers that this is the greatest state in the United States of America. We don’t make excuses. We make the impossible happen… We’re going to run these trains on Jan. 1, and we’re going to remind New Yorkers that there is nothing that we cannot do in this state when we put our mind to it and we’re not going to take no for an answer.”

The sentiment is noble, but the reality is not. In 2007, the MTA said it could do the job for a little under $4 billion, and would be finished by the summer of the 2014. It's now December 2016, and these three stops have cost $4.5 billion.

Budget and time overruns were not even the biggest problem. Come 2017, New Yorkers won't have a full Second Avenue Subway from the Bronx to Brooklyn, as promised by our forefathers. They will have just three stops, from 96th Street to 72nd Street, feeding commuters who live in this area into the existing stop at Lexington Avenue and 63rd Street to bring people further downtown to their jobs.

True, the stops are climate-controlled, accessible to the handicapped, and nice and new—but they're still just three stops. These three stops, the MTA says, will alleviate crowding on the overpacked lines to the West. But they're also likely to draw new people to the subway, causing more crowding further down the line.

So what went wrong with the new, improved—and, come Saturday, existent—version of Second Avenue Subway? Let’s disabuse ourselves of a romantic notion: that we can go back to the way things were a century ago, when cities threw up bridges and buildings in months. That wasn’t even true back then; the city’s first subway—the ones we actually built—took more than a decade to plan and build. That’s despite an advantage the city had back then but doesn’t have now: Back then, it didn’t have to spend billions each year to maintain infrastructure that was decades old. It was building all-new infrastructure.

Construction firms could work faster back then, though, because society didn't have the same regard for human life, or the knowledge of how to protect life: In one subway-construction incident in 1903, the worst such catastrophe in New York history, 10 workers were killed.

Nor did firms have to follow any environmental regulations. Firms could work all night and day simply digging out dirt and flinging it to the side under “cut and cover” construction. Today, they must do their work with some minimal consideration for the neighbors, burrowing deep underground to avoid destroying what is above, and testing air quality and easing night work for the unavoidable above-ground work.

***

Still, we can do a better job within modern-day constraints. First, we should stop hyper-cyclical planning. Though the state-run MTA didn’t officially start the latest Second Avenue project until 2007, the city and state began planning for it around the turn of the century (the new century). That’s because around the year 2000, the national, state, and local governments were flush with cash. The federal government, which paid for a third of the project, was looking at indefinite budget surpluses; the city was nearing the end of a stock-market boom that had sent employment in the financial industry to a level it’s never surpassed.

New York thus went from building nothing in three decades to building everything at once: not just the Second Avenue Subway, but a new commuter-rail link to East Midtown and faster work on a new water tunnel. Starting all of this work at the same time by itself pushed up costs. The city has only so many contractors who can bore tunnels, and multiple projects were competing for those contractors, driving costs up. At the same time, we were competing with China for raw materials such as steel and cement, pushing those costs up, as well. (The rebuilding required by the 9/11 attacks, a year later, didn’t help.)

Second, the city must be more realistic about labor costs. In New York, because of both state and federal laws, a basic laborer earns $79.63 an hour, including benefits; an ironworker earns $96.69. These are hard jobs to do, and merit good pay. But union rules keep productivity low. New York requires twice as many to five times as many workers on a tunnel-boring machine compared to non-union states and European countries.

Third, obscure federal mandates cost money. On the Second Avenue Subway, for example, the federal government and New York's MTA bickered for more than a year about whether a fire-suppression system met longstanding federal “buy America” mandates. The MTA, through a contractor, had sourced part of its fire-suppression system from Finland.

The state tried to argue that the components made in Finland were not an “end product.” The Finnish had made pipe tubing, valves, and nozzles, but the Americans had made pipe fittings, a controller unit, alarms, and measuring tools. The federal government, however, ruled that the system was out of compliance, and that the MTA had to replace it. It's hard to believe that the purpose of our long-standing mandates on American companies are to protect us from well-paid Finnish workers. Nevertheless, one-off problems such as this one add up.

Fourth, the Second Avenue Subway, like other New York projects, suffered from the MTA's inability to properly coordinate the private-sector contractors who do much of the public-sector's construction work. As one group of workers finishes one section of project, another group of workers should be ready to step in to start work on another section.

Yet over and over, one contractor's delay cascades into delaying other contractors from starting their work. New York could address this problem by allowing public agencies to award “design-build” contracts, under which a contractor takes on the responsibility of completing an entire project, shouldering the risk of non-coordination itself. Yet New York, in part because of union pressure, restricts design-build contracting.

Finally, New York’s infrastructure projects continue to suffer from pressure from other types of spending. Separating the transit system from the rest of the city and state budgets was supposed to ameliorate this problem, but it hasn’t. Consider: If New York City could reform its public-sector pension benefits, and spend just $7 billion on pensions annually instead of $9.8 billion, it would have enough money, in three years’ time, to build three more stations of the Second Avenue Subway. But separating infrastructure spending from other spending has had a perverse effect: It prevents politicians from thinking in such terms.

***

If New York doesn't address some of these problems, it's not unreasonable to think it will be another 100 years before we have a full Second Avenue Subway. But these aren't lessons just for New York. From Boston's Big Dig to San Francisco's Bay Bridge, America's major projects come in decades late and billions over budget—harming the public's support for more infrastructure investment. Though each mega-project fails in a slightly different way from all the rest, they share commonalities, including inefficient labor practices and subservience to expensive federal mandates.

The tale of the Second Avenue Subway, then, is a lesson for President-elect Donald Trump, as he embarks, perhaps, on a trillion-dollar infrastructure scheme. The very act of building too much at once itself pushes costs up, and signing provisions such as even tougher “Buy America” requirements into law to protect American workers are complex and expensive to implement.

In the meantime, though, New Yorkers should celebrate their new subway line. One thing is for sure: they won't be getting another one come next New Year's Eve.