This is the crux of it. The notion that economics, as a field, was blindsided by the rapidity and extent of economic dislocation doesn't match the history. Such a narrative is a whitewashing of a particular clique of superstar economists, which explains why Krugman is so committed to it despite his current policy views.
I was studying International Affairs as an undergraduate in Washington, D.C. in the late 1990s. These issues were well known and heavily discussed, domestically and internationally. By the late 1990s the notion of controlled, incremental trade expansion as espoused by people like Prime Minister Mahathir of Malaysia was already on the upswing in the international community and cemented after the 1997 Asian financial crisis. That is, while mainstream economists were highly skeptical about the efficacy and unintended consequences of such industrial strategies, not to mention of the leaders like Mahathir who espoused them, it was impossible to deny the fundamental premise that the existential risks of too-rapid global trade expansion were very real.
The problem in the U.S. was much the same problem we've always had: free trade became synonymous to opposition to government intervention. All the free trade bills in the U.S. invariably included funding for re-education and R&D to help manage dislocation and build competitive advantages, but they were meager financially and suffocated by neglect. And that's because these measures were considered "government intervention" and hedges to preserve "big government", which as we all know as Americans (and, to a slightly lesser extent, everybody else in the Anglosphere) meant naivety, ineffectiveness, and corruption. So it's no surprise that the American public and politicians drifted toward a fundamentally broken policy situation.
This is no less true today even as we've soured on the notion of free trade. We'll put up trade barriers, but we still refuse to heavily invest in re-education and R&D, and not even our most liberal policymakers have proposed an industrial policy aimed at managing globalization. Just the same 20-30 years ago, these things are synonymous with big government, corporate subsidies, etc. Instead, we limit free trade presuming that the domestic industrial economy will naturally restore more equitable employment and wealth distribution.
Nothing about free markets guarantees "equitable" distribution; indeed, history has proven that they often tend to distributions that are untenable democratically. But we're even less prepared to effectively manage this stuff for our domestic economy than we are for international trade. Anybody expecting our social equities to substantially improve simply because we're limiting free trade is delusional, though they're in good company.
The thing is, we can never put the free trade genie back in the bottle. And the truth is, on balance free trade is better for the world and for every nation in it; just as with free markets more generally. The problem as always is managing dislocation and wealth distribution. We need to learn, as a society and as economists (armchair or otherwise--I'm not an economist), to stop equivocating industrial policy with government control. Until we do that, we'll never be able to discover and identify the levers and strategies available for mitigating the disruptive aspects of free markets while minimizing the risks of corruption.