Did the Paris climate accord save civilization? Maybe. That may not sound like a ringing endorsement, but it’s actually the best climate news we’ve had in a very long time. This agreement could still follow the path of the 1997 Kyoto Protocol, which seemed like a big deal but ended up being completely ineffectual. But there have been important changes in the world since then, which may finally have created the preconditions for action on global warming before it’s too late.

Until very recently there were two huge roadblocks in the way of any kind of global deal on climate: China’s soaring consumption of coal, and the implacable opposition of America’s Republican Party. The first seemed to mean that global greenhouse emissions would rise inexorably no matter what wealthy countries did, while the second meant that the biggest of those wealthy countries was unable to make credible promises, and hence unable to lead.

But there have been important changes on both fronts.

On one side, there is a visible shift in Chinese attitudes — or at any rate, a shift that would be visible if the smog weren’t so thick. Seriously, China faces a huge air quality crisis, brought on largely by coal-burning, which makes it far more willing to wean itself from the worst form of fossil fuel consumption. And China’s economic growth — real income per capita has quadrupled since 1997 — also means that it has a rapidly growing middle class that demands a higher quality of life, including air that’s relatively safe to breathe.

So China is playing a very different role now than it did in the past. One indicator: some of the usual suspects on the right have suddenly changed their line. They used to argue that U.S. emission limits would be useless, because China would just keep polluting; now they’re starting to argue that U.S. action isn’t necessary, because China will cut coal consumption whatever we do.