In 1979, the US suffered the twin ignominies of the Iran hostage crisis and the Soviet capture of Afghanistan. Inflation took off as the helpless president evoked (without saying the word) a malaise. In garlanding The Deer Hunter, the bleakest film of Hollywood’s bleakest decade, the Oscar judges met the national mood.

It is against fearsome competition, then, that 2020 stands out as the nation’s worst peacetime year since the Depression. The coronavirus pandemic has taken 320,000 American lives. The ensuing recession was the deepest that most people alive have ever known. Racial fractures widened and President Donald Trump tried to undo his electoral defeat to Joe Biden.

To salvage the positives from such a year will strain credulity. To suggest that Americans can end it with enhanced confidence in their republic will test the boundaries of good taste. And still the case is there to be made.

In March, an allegedly irredeemable political class brokered the largest programme of fiscal relief in US history. It has been fitfully topped up ever since and a deal to the tune of $900bn passed Congress on Monday. Those who had hoped for more and better should concede that Washington has already outperformed dismal expectations. There was nothing inevitable about the scale of the largesse (Republicans control the Senate), its speed (the bank bailout of 2008 was at first voted down) or its imagination (unemployment benefits were reformed at pace). The passage of the March bill through Congress was all but unanimous.

It is one thing for China, or even a democracy as centralised as the UK, to take big and swift action in a crisis. For the US to do the same implies something good about its political model and the individuals who people it. To say so should not feel as subversive as it does.

As well as a once-in-a-century shock, the system was put through a more foreseeable stress test this year. Again, its show of resilience is on course to be glossed over. With Republican connivance, Mr Trump has tried to subvert the result of a free and fair election. The seriousness of his intent should not get lost in the vaudeville of botched litigation and oddball plaintiffs. But then nor should the thoroughness of his failure. From the district courts of Michigan and Pennsylvania up to the Supreme Court, judges threw out frivolous claims of voter fraud. Some of them owed their place on the bench to Mr Trump himself. Other gambits to the same end flopped without Mr Biden having to dignify them with much of a public response.

It is customary at this juncture to say that a cannier populist might one day succeed where Mr Trump failed. But the idea that an autocratic nearly-man must prefigure the real thing is too often written up as a teleological inevitability. The Republicans who succeeded Richard Nixon were Gerald Ford, Ronald Reagan and George H W Bush, not a gallery of sublime rogues.

A proper transfer of presidential power, timely relief for blameless hardship: these should be givens, not mercies to be cherished. Yet only the sunniest soul would have counted on them this time last year. It was smarter to assume that partisanship would get in the way. The biographer Robert Caro says that “power reveals”. Well, so does trauma. Americans know much more about their system than they did before the pandemic and contested election.

The findings are not unambiguously benign. Mr Trump has shown that a president can do almost anything and remain competitive (the closeness of the election should trouble liberals more than its attempted annulment). As for the pandemic, easing the economic costs is not the same as smothering it at the root. The UK and Spain and Italy are the few nations with more deaths per 100,000 people.

It is just that a direr scenario was eminently plausible. It was averted by the conscious acts of public office-holders under extreme duress. The non-occurrence of disasters should not go unrecorded and uncelebrated. It is how cynicism about politics attains its spurious credibility.

As China avoids recession, it was prudent to cite 2020 as a grudging baton exchange from an ailing superpower to a rampant one. And perhaps even from multi-party democracy to more hierarchical modes of government. It matters to the cause of liberalism, then, not just to American pride, to hail the US system’s quiet resilience. The alternative is to do down the institutions that made a potentially terminal year merely dreadful. The trouble with pessimism is that it can be self-fulfilling.