The eyes of the political world are fixed on the Sixth District of Georgia, located in the upscale northern suburbs of Atlanta. Last week, Democrat Jon Ossoff stunned many observers by winning 48 percent in an all-party “jungle” primary; in June, he will face Republican Karen Handel in a runoff.

The Georgia Sixth has a long Republican history; Newt Gingrich represented it when he was speaker of the House, and GOP candidates usually win here by double-digit margins. (It is not the same district that elected Gingrich from 1978 through 1990 — the Sixth’s lines were altered radically by Georgia Democrats in an unsuccessful effort to push Gingrich out of Congress. But it’s safe to say that the territory that makes up the current Sixth has been safely Republican since the Nixon era.) It was vacated when Rep. Tom Price was confirmed as Donald Trump’s secretary of health and human services.

The race to fill the Sixth has at least two unusual features. First, while the district is traditionally Republican, Donald Trump seriously underperformed here, winning it by a 1.5-point margin. Suburban Atlanta’s highly educated, high-income residents did not warm to Trump’s populism or his outrageous persona. So while the GOP appeared to enjoy an advantage, Democrats had an opening.

Second, the jungle primary posed serious problems for both parties. Republicans quickly attracted several candidates, including “insiders” like former Secretary of State Karen Handel, state Sen. Judson Hill, and former state Sen. Dan Moody, as well as some self-styled “outsiders.” The Democrats, without much of a bench in this country club GOP territory, did not have any well-known candidates. (The district’s only prominent Democratic officeholder, state Rep. Scott Holcomb, passed on the race early.) Given their weak presence in the Sixth, Democrats risked being shut out of a runoff. In both cases, the formal parties could not actually endorse candidates in the “jungle” primaries.

Actors in both parties faced significant collective action problems. Democrats risked scattering their votes, and potentially not making the runoff. Ossoff, a 30-year-old documentary filmmaker who had been an intern for Rep. John Lewis and had worked for Rep. Hank Johnson, was completely unknown to voters (though not to Atlanta-area Democratic insiders). But an early endorsement by Lewis — an icon of the civil rights movement, the Democratic Party, and modern Atlanta — quickly boosted Ossoff’s national profile.

Potential rivals, such as lawyer Josh McLaurin and long-ago state Rep. Sally Harrell, ducked out of the contest. Other Democratic candidates, such as Clinton-era state Sen. Ron Slotin, soon found themselves shunted aside. On January 26, Daily Kos Elections announced that it was endorsing Ossoff. The money began to roll in. Within a month, the DCCC announced that it was sending nine field staffers to the district. An NRCC ad that memorably mocked Ossoff for dressing up as Han Solo as a college student only brought him more attention. The Planned Parenthood Action Fund backed Ossoff with digital ads, mail, and a field campaign.

In the end, Democrats solved their problem beautifully. Ossoff raised $8 million by the end of March. In the April 18 runoff, he received 48 percent of the vote; only 1 percent of voters backed the other Democrats. Ossoff managed to mobilize the Democratic base while running a campaign with broad appeal. (His ads are models of courting the median voter.)

While the conventional wisdom has long been that only extremist candidates can raise large sums from small donors, Ossoff courted his supporters not with ideology but with “Make Trump Furious.” The Daily Kos endorsement didn’t call for a socialist revolution. Instead, it focused on the most brass-tacks aspects of politics: Ossoff’s early fundraising success, his endorsements by Lewis and other Georgia Democrats, Trump’s relative weakness in the Sixth, and the need for Democrats to consolidate early behind one candidate.

Republican Party organizations could not get behind a particular candidate, and local GOP bigwigs quickly scattered their endorsements. As Ossoff gained strength, Republicans worried that he might win the primary without a runoff. Not only was he consolidating Democratic voters but Republican enthusiasm seemed low, and turnout could have easily disappointed.

As a result, the NRCC, the Georgia Republican Party, and the Congressional Leadership Fund entered the race, both on the air and on the ground. They sought to stimulate Republican turnout and drive up Ossoff’s negatives. These are both traditional roles for party committees and interest groups. The GOP organizations were also performing actions that the candidates on their own could not. The National Rifle Association also sponsored radio ads attacking Ossoff.

But other groups played roles less supportive of Republican Party goals. The Club for Growth, long active in Republican primaries, funded ads supporting former Johns Creek council member Bob Gray and trashing Republican frontrunner Handel. The 45 Committee and Ending Spending, two murky groups with ties to Ameritrade founder (and Republican megadonor) Joe Ricketts, sponsored ads supporting Handel and attacking both Gray and the Club for Growth. Gray was also attacked by a dark-money group called Americans United for Values, whose ultimate backers are unknown.

Groups backed by a small number of very wealthy individuals (or whose funders are unknown) pose different questions than do high-profile, mass-membership organizations like the NRA and Planned Parenthood. (Handel also benefited from the backing of right-to-life organizations, long a force in GOP primaries.)

The primary taught another lesson about the Republican Party: There is not much sign of a “Trump faction.” Businessman Bruce LeVell, who had been a member of Donald Trump’s diversity coalition and was endorsed by Trump sidekick Corey Lewandowski, received 0.24 percent of the vote. (Veteran Tea Party activist Amy Kremer performed even worse). Gray also associated himself with Trump (despite his backing by the sometimes Trump-skeptical Club for Growth) and performed much better, but still finished a distant second to Handel among Republicans.

So what are the lessons of this race? Well, that even in situations where there is no formal party endorsement, parties can solve coordination problems, as the Democrats did. Even if Ossoff does not ultimately win, his strong showing seems to be adding to rising Democratic morale nationwide. Democrats want to be competitive in suburban and Sunbelt districts similar to Georgia’s Sixth, and already top-tier candidates are jumping into those races. Party organizations can also provide collective goods when they are unable to back particular candidates, as the NRCC and the Georgia Republican Party did. Democrats are highly motivated to oppose Trump and all his works, while Republicans don’t seem particularly interested in backing Trumpish candidates.

The roles played by interest groups and other “party network” actors tell some complicated tales. While the surge of Democratic mobilization has exploded the ranks of local party activists, it has also fueled the growth of organizations outside the formal party, such as Indivisible. One could imagine how such groups could be problematic, given the GOP’s complicated history with the Tea Party. But Indivisible was created by former Democratic congressional staffers, and has seemed unwilling to embrace a systematic policy message beyond “resist Trump.” (In my perhaps-unrepresentative experience, many local Democratic activists are also involved in Indivisible chapters.)

Given that most Democratic officeholders seem happy to resist Trump as well, it’s perhaps not surprising that Indivisible has not yet spawned any primary challenges. Democratic activists seem mostly motivated by anti-Trump sentiment rather than purist crusading. Indeed, when Bernie Sanders refused to endorse the not-so-ideological Ossoff, the outcry was such that the senator quickly reversed himself.

The NRA and Planned Parenthood, two huge (and popular) issue groups with strong party ties, mostly stuck to actions that would help “their side” capture the Sixth. The Congressional Leadership Fund, under the control of the House GOP, followed the same path as other Republican organizations.

It’s hard to see why groups like the CLF shouldn’t be considered de facto party committees. It’s also true that it’s hard to see the justification for a campaign finance system that leads to odd workarounds like the CLF to accomplish ordinary party functions. The role of the Club for Growth is more troubling, given its heavy activity in Republican primaries on behalf of highly ideological candidates and its backing by a small number of wealthy donors. But the story of the Georgia Sixth was mostly of parties able to accomplish their goals under unusual conditions.