So what did Democrats do right? How did they hold it together? Among the many factors, three come quickly to mind:

1. The troublemakers are gone. The Democratic caucuses were far more unruly in 2009 and 2010, when efforts to pass a stimulus, health care reform, financial regulation and climate change legislation produced squawking and dissent from conservative Democrats. But when the House Democrats lost their majority in the 2010 midterm, it was because they lost a bunch of more conservative members in marginal districts. As their ranks shrunk, they became more unified. Meanwhile, the Senate Democratic caucus has bid farewell to Blanche Lincoln, Kent Conrad, Ben Nelson, and Joe Lieberman—all more conservative and all (but particularly Lieberman) inclined to make trouble for party leadership. The ideology of the Democratic caucus shifted, but so did the temperament. “With their departure, and with the addition of Elizabeth Warren and some others, the caucus got a lot more progressive,” says Jim Manley, former spokesman for Ted Kennedy and then Harry Reid. “Both Nelson and Lieberman were the kind of senators who were always demanding to cut deals with Republicans.”

2. Republican crazy brings people together. The Senate still has some conservative Democrats, of course—Joe Manchin of West Virginia comes quickly to mind. But the agenda has changed a lot since 2009 and 2010: Instead of trying to enact their own policies, in this episode, at least, Democrats were mostly trying to stop Republicans from passing theirs. And that wasn’t so hard, given the nature of Republican tactics. Polls showed repeatedly that, despite the public ambivalence about Obamacare, majorities did not support shutting down the government in order to undermine the law. And as the shutdown wore on, it became clear that Republicans, not Democrats, were taking the blame. It helped, too, that prominent Senate Republicans were openly critical of what Ted Cruz and his House Republican allies were trying to do. With the lkes of Bob Corker, Lindsey Graham, and John McCain all speaking out against the shutdown and threats on the debt ceiling, conservative Democrats had plenty of political cover for sticking with their party.

3. The Democratic leaders were tough. Lots of Republicans had their doubts about the shutdown-debt ceiling strategy. But many went along because they figured Obama would give in. He didn’t—and it’s not surprising why. He saw Republican tactics as an existential threat, not just to his own presidency but to the presidency as an institution. As Jonathan Chait had started pointing out months ago, Obama couldn’t give in. Pelosi, as usual, held her caucus together—even though it meant telling them, at times, to take tough votes or settle for less than they wanted. (As she pointed out on more than a few occasions, with obvious reference to Boehner, that’s what leaders do.) And then there’s Reid, whose ability to keep the caucus together—and to take a hard, no-negotiation line against Republican tactics—made him a hero not just among his own colleagues but among his House counterparts and outside groups as well. “This victory for common sense is a testament to his profound tenacity, the trust his colleagues have in him and his ability to lead,” says Neera Tanden, president of the Center for American Progress. “And it is clear it would not have happened without him.”