In the early morning hours on Wednesday, Conor Lamb came out on a stage at a hotel in Canonsburg, Pennsylvania, to say that he’d won the special election for the state’s Eighteenth Congressional District seat. “We did it!” he said, smiling—even though, technically, he hasn’t won anything yet. His margin was slightly more than six hundred votes, out of more than two hundred thousand cast, but he has good reason to think that, even with a couple thousand absentee, provisional, and military ballots still to be counted, the whole thing will go his way. And, in truth, he had other reasons to declare victory. First, he had shown that a Democrat could win, or at least reach a tie, in a district that President Donald Trump had won by nineteen points. Lamb is thirty-three, a former Marine captain, military lawyer, and federal prosecutor, and his bright cheer, in Canonsburg, seemed to illuminate a disproportionately large political space.

The second reason is somewhat more complicated, both for him and for the Democratic Party. Unless courts intervene, which doesn’t seem probable at this point, the Eighteenth Congressional District is about to be scrambled in Pennsylvania’s redistricting and will no longer exist, as it is now, by the time of the midterms in November. The territory that Lamb fought Rick Saccone, the Republican, over, and for which their parties and related PACs spent what may turn out to be well more than ten million dollars, is going to be divided, mostly, between the newly conceived Fourteenth and Seventeenth Congressional Districts. Saccone has said that he will try to run in the Fourteenth in November. Lamb has deflected the question of where he will run, but his home and, likely, his best prospects are in the Seventeenth, which will encompass only Beaver County and a part of Allegheny. They have only until next Tuesday to gather signatures and file for the election, which means that both men will likely be running again in a matter of days—just not against each other. And by then the Democrats will also need to have a clearer picture of what, exactly, they think the lessons of Conor Lamb’s run might be, not only for Trump but for their Party.

Why was there a special election for a seat that is going to cease to exist, anyway? Because the incumbent, Tim Murphy, resigned after the Pittsburgh Post-Gazette reported on a text-message exchange between Murphy and a woman with whom he was said to be having an affair. Murphy is married, but the bigger problem was that the woman was writing to say that she was upset with him for posting an anti-abortion statement on his Facebook page, “when you had no issue asking me to abort our unborn child just last week when we thought that was one of the options.” Perhaps an even bigger problem was Murphy’s response to the woman, in which he compounded his alleged hypocrisy by seeming to claim ideological emptiness as a defense, saying, of his anti-abortion statement, “I’ve never written them. Staff does them. I read them and winced.” Politics, in general, can make a person wince.

It is fair to say that, for a lot of people, this election was about Donald Trump. The President came to the district days before the vote and, at a large, boisterous rally, asked people to support Saccone for his sake. And, although he didn’t say much else about Saccone, he did come up with a nickname for Lamb—“Lamb the Sham”—and it means something that it didn’t stick. (Trump also said, of Lamb, “I think I’m better-looking than him.”) People around Trump have nonetheless tried to get out the message that the race didn’t really have much to do with the President; there was word, for example, that Ivanka Trump, having met Saccone, had not found him charismatic. But she had also been campaigning in the Eighteenth, which suggests that some reassessment of the effect of her own charisma on voters may now be in order. Donald Trump, Jr., campaigned with Saccone, too, and, as NBC News reported, was standing next to him when he said, of his opponents, “Many of them have a hatred for our country. I’ll tell you some more—my wife and I saw it again today, they have a hatred for God.”

Conor Lamb did not fit that profile—not that anyone, in either political party, really does. (What does it even mean to have a “hatred for God”?) As my colleague Eliza Griswold noted in a dispatch from the Eighteenth, Lamb is well attuned to the district. For some Democrats, he might be a little too much so—for the future, if not for this race. In his first ad, mention of his military service was followed by a shot of him at a firing range with an AR-15-style weapon and a voice-over attesting that he “still loves to shoot.” He also appears to be opposed to most gun-control measures. He has said that he personally opposes abortion but would respect the law of the land in that regard. He made it clear that he likes both unions—which came out in force in support of him—and President Trump’s steel tariff. He campaigned with Joe Biden, and spoke about defending Social Security and other social programs against Paul Ryan, but presented himself as an opponent of Nancy Pelosi. And he tried to shake off the idea that this election was a referendum on Trump; Lamb’s criticisms of Trump himself have been directed more at his tone, and at the general tone of American politics today. The value of all this depends on the lesson that the Democratic Party draws for 2018: Will it be that candidates should put out pictures of themselves firing high-powered weapons? That it is foolish to impose litmus tests? Or just that candidates should know, and be known in, the districts where they run, and—without changing who they are fundamentally—know what it takes to win them?

To take another example, Lamb told Griswold that, when he was out campaigning and people asked about his party, “I just say, usually, ‘Look, I’m a Democrat because my grandfather was a Democrat, and he was because F.D.R. was.’ ” Similarly, on election night, he said that he was the candidate of the party “of my grandfather” and of F.D.R. One lesson here is that Democrats should not be afraid to fight for the allegiance of voters who have left them behind. Lamb made that point in his victory speech, saying, “We went everywhere; we talked to everyone.” President Barack Obama has made that point, too. But there is a risk of coming up with a more cartoonish version of that insight, to the point of acting as though F.D.R. were the last Democratic President it was safe to talk about.

The wrong lessons can also be arrived at when other aspects of the dynamic between the candidate and the electorate are ignored. The Eighteenth is, demographically speaking, one of the older districts in the state. (It is also overwhelmingly white.) Many voters there, when they hear Lamb talk about his grandfather, may be picturing their own western Pennsylvanian grandfathers. But some number will also be thinking about Lamb’s particular grandfather, Thomas Lamb, who was a local politician and, at one point, the Democratic leader in the State Senate, as well as both a trustee and a lobbyist for the University of Pittsburgh. When Lamb announced his candidacy, last fall, his uncle, Michael Lamb, who is now the Pittsburgh city controller, was on hand to tell the Post-Gazette that his nephew “has always been very committed to the idea of justice.” Lamb himself had never run for office. But the circumstances make this less than a perfect test of whether neophytes or those with institutional backing make for the strongest candidates, since there are ways in which Lamb was both. The best lesson might be, again, that candidates matter, and voters do, too—voters as people who are appealed to, not simply as demographic profiles.

Further Reading New Yorker writers on the 2018 midterm elections.

And what does that mean for the campaign in November, the one that will matter in terms of who will represent this part of Pennsylvania for the next two years and perhaps, given the advantages of incumbency, many more? There are several candidates in what had been the Twelfth District who have already started running in what will be the Seventeenth—where Lamb may run, too—against the Republican candidate, Keith Rothfus, who is seen as vulnerable. The Seventeenth will not be as conservative as the old Eighteenth, and a victorious Democrat might not need to be, either. (One candidate, a local lawyer named Beth Tarasi, went to the University of Pittsburgh on a scholarship to play for the women’s basketball team; she supports gun control and Planned Parenthood more openly.) Perhaps national Democrats are so far into their commitment to Lamb that the debate over what it means to be a Democrat now, in Western Pennsylvania or anywhere, is less important than consolidating an unexpected and important victory in an engagement with Trump. They won where they hadn’t before, and it has sent the message that they can win everywhere.

Lamb, speaking to CNN on Wednesday morning, said, “This is my home. You call it a red district, I call it Western Pennsylvania.” That seems right. But he was also asked whether he thought that his victory said something about Trump. He replied, “Not really, other than to say that there are plenty of people here who are still pretty supportive of him.” People in both parties would argue otherwise. Lamb added that he had seen plenty of Trump bumper stickers on cars parked outside the polls, and he was sure there were people who had voted both for Trump and for him. That is surely true, too, but raises a bigger question: Whom will they vote for next?