Congress made its most aggressive use ever of the War Powers Act to end an ongoing conflict at the end of 2018, with the Senate approving — and the House coming just short — a resolution that would have required the United States to end its support for the Saudi-led war in Yemen.

On Wednesday, Sen. Bernie Sanders, I-Vt., and Rep. Ro Khanna, D-Calif., re-introduced that resolution, and with the House in Democratic control, it’s expected to pass both chambers this year and head to the president’s desk, setting up a confrontation over U.S. involvement in the war.

Since 2015, the United States has provided logistical support to Saudi Arabia, in addition to tens of billions of dollars in arms sales. The resolution, which seeks to end that, picked up momentum in the wake of the butchering of journalist Jamal Khashoggi inside the Saudi consulate in Istanbul.

But inside the House, a much lower-profile development played a critical but overlooked role: a Democratic primary campaign in Washington state. Significant credit for that resolution’s earlier momentum, say people closely involved in the process, belongs indirectly to Sarah Smith, a long-shot congressional candidate who challenged Democratic Rep. Adam Smith in Washington last year, making it to the general election before losing. Adam Smith at the time was the top-ranking Democrat on the Armed Services Committee and is now the panel’s chair, and Sarah Smith mounted her challenge largely in opposition to what she cast as his hawkish foreign policy approach, with a specific emphasis on Yemen.

Adam Smith, facing the challenge from Sarah Smith, became an outspoken advocate of using the War Powers Resolution in the fall to go up against the Trump administration, including by becoming a leading sponsor of a new War Powers resolution on Yemen. Now that he has won re-election, he remains a supporter of the effort, but his enthusiasm for it has changed noticeably.

WASHINGTON, DC - APRIL 12:  House Armed Services Committee ranking member Rep. Adam Smith (D-WA) questions witnesses during a hearing in the Rayburn House Office Building on Capitol Hill April 12, 2018 in Washington, DC. The Trump administration's top war-fighters, U.S. Defense Secretary James Mattis and Chairman of the Joint Chiefs of Staff Gen. Joseph Dunford, testified before the committee about their FY2019 defense budget request, the possible military response to alleged chemical attacks in Syria and other subjects.  (Photo by Chip Somodevilla/Getty Images)

House Armed Services Committee ranking member Rep. Adam Smith (D-WA) questions witnesses during a hearing in the Rayburn House Office Building on Capitol Hill April 12, 2018 in Washington, DC.

Photo: Chip Somodevilla/Getty Images

“The War Powers resolution thing,” Smith told trade reporters who cover the Pentagon and the weapons industry in a post-election interview in December, before groaning. “There’s no way in the world you can write these stories that’s going to come out in a way that’s positive for me, but I’ll say it anyway: The War Powers resolution is only so useful.”

His shift in rhetoric underscores the impact primary challenges can have on internal House politics, but it also could make him vulnerable to another challenge in two years.

“Primary challenges put pressure on Democrats in many blue districts to be more accountable to progressive and Democratic voters in their districts.”

“For nearly a year Adam Smith faced a primary challenge from Justice Democrat Sarah Smith who routinely brought up his hawkish foreign policy views and campaign donations from defense contractors as central issues in the campaign,” said Waleed Shahid, a spokesperson for Justice Democrats, which backed Sarah Smith’s candidacy. “In many of our races, even when we lost, there was a clear ‘primary effect’ when Democratic incumbents started to embrace more progressive policies and rhetoric. Primary challenges put pressure on Democrats in many blue districts to be more accountable to progressive and Democratic voters in their districts.”

Adam Smith might think it’s hard to write this story in a way that comes out positively for him, but let’s try anyway. It’s fair to say he is not by any stretch the most hawkish member of Democratic leadership and is regarded by progressive foreign policy advocates as somebody who’s willing to work with them. “From Afghanistan to Yemen to the budget, it’s never been Smith we had to move, to be honest,” said one advocate who works with Smith, but asked not to be named for fear of repercussion from House leaders. “Sometimes his staff severely holds him back, but often, he’s been rather helpful behind the scenes in triangulating to move Steny off one bad position or another,” the advocate said, referring to Rep. Steny Hoyer, D-Md., a pro-Israel hawk and the No. 2 Democrat in the House.

Smith is a politician, and even if his primary race, and the anti-incumbent mood that swept the party in 2018, influenced his Yemen posture, there’s nothing inherently immoral with taking into account the views of the public when it comes to public policy positions. According to people involved with the effort to pass the Yemen resolution, the starkest change in Smith’s approach came in the wake of the June 26 primary victory by Alexandria Ocasio-Cortez in New York, who shocked the political world by unseating Joe Crowley, who was in line to be speaker of the House.

That appeared to focus Smith’s mind on his own primary election, scheduled for August 7. Washington state uses a top-two system, meaning that all candidates run in the same primary, and if the top-two finishers are from the same party, both of those candidates go on to the general election. Polls showed that Sarah Smith, dogging him relentlessly, was in striking distance of finishing second.

Ocasio-Cortez’s upset victory had confused many veteran politicians, who sensed that things were changing, and nothing could be taken for granted. Throw in two people named Smith on the ballot, and things could go terribly wrong for one of them. When the primary came around, Adam Smith was the top vote-getter, and Sarah Smith narrowly edged out the top Republican challenger, winning the second spot on the general election ballot.

“All of a sudden, Adam started to change his tune.”

Sarah Smith said she could sense Adam Smith becoming less hawkish in real time. “I went after him about Yemen every time I got an opportunity to and I kept hammering him. When Ro [Khanna] was leading the charge, I started talking about how Ro is a junior congressman in his first term and he is leading on this, where Adam has failed for years, and I talked about how we didn’t just get involved in Yemen. And then Alex [Ocasio-Cortez] won and people started noticing my campaign and me talking about getting us out of Yemen and they started to become very interested, and all of a sudden, Adam started to change his tune,” Sarah Smith said.

Adam Smith rejects this characterization entirely. “I was actually on the Yemen stuff before I even knew she existed,” he told The Intercept. “It’s not just about Yemen, it’s about Saudi Arabia more broadly, the authoritarian crackdown, obviously the murder of Khashoggi. They are becoming more and more lawless in the way they’re acting and not just in Yemen, but elsewhere. … I’m happy to push our administration and Congress to do more on that issue.”

His opposition to U.S. involvement in Yemen, however, became decidedly more forceful as Sarah Smith’s candidacy became more potent. In 2016, Smith was just one of 16 Democrats to vote against defunding Saudi Arabia’s use of cluster bombs. On July 26, 2018, Smith trumpeted his success in winning restrictions on war activity in Yemen in a defense appropriations bill passed by the House. It wasn’t terribly strong, however. The bill, also backed by Khanna, prohibited the U.S. military from providing in-flight refueling to Saudi and other coalition aircraft involved in the Yemen war, unless the secretary of state could certify that “the governments of Saudi Arabia and the UAE are taking certain actions related to the civil war in Yemen.”

On September 6, a month after Sarah Smith clinched a primary win, Adam Smith announced that he was introducing a War Powers Resolution, with Khanna, and Mark Pocan, D-Wisc., to end the Yemen war.

Given his perch on the Armed Services Committee and his influence on matters of foreign policy, Adam Smith’s public push for the resolution was a signal to rank-and-file Democrats that it was an issue worth supporting, and the party broke en masse in favor of the resolution. Both Hoyer and Rep. Eliot Engel, D-N.Y., who chairs the House Foreign Affairs Committee and is another leading hawk in the House, endorsed the Yemen resolution in late September.

Adam Smith went on to win the general election easily, beating Sarah Smith, 68-32. A week after Election Day, House Republicans beat back the resolution. A month later, it came up again, and this time it barely failed, with five Democrats voting with Republicans against it.

That same morning, Smith sat down with the trade reporters to offer his pessimistic take on the resolution.

His anger at how Saudi Arabia and the UAE were carrying out the war — “the closing of ports, the cutting off of aid and food, a relentless bombing campaign, and the civilian devastation that’s resulted from that is largest humanitarian crisis in the world” — was undiminished, but the War Powers Resolution wasn’t going to stop it, he said, Breaking Defense reported.

He noted that U.S. presidents have almost unfettered control over the military, and that Congress would have to completely cut funding from the military to block the president’s actions. “It’s not so much that the War Powers Resolution is going to make the administration go, ‘Oh, shit, well we really wanted to do this, but since you hit us with this, we won’t,’” Smith told the reporters in December. “It’s that it will put public pressure on them to change what they are doing — and we’ve already seen they’ve stopped the refueling.”

When Smith referenced the resolution that he and Khanna had introduced, he characterized it as solely Khanna’s resolution. “I’ve worked with Ro Khanna, and even in his resolution, he makes it very clear he’s not stopping us from confronting Al Qaeda and other terrorist groups within Yemen,” Smith said. Indeed, the resolution carved out an exception for U.S. operations targeting Al Qaeda in the Arabian Peninsula.

Despite doubting the effectiveness of the resolution, Smith said that Khanna and Sanders’s efforts are important “because it raises awareness and attention to the problem and the question of what we ought to be doing in Yemen.”

That type of endorsement, however, leaves plenty of room for advocates of war to believe that the chair of the Armed Services Committee is no longer part of the Sanders-Khanna posse working furiously to end U.S. involvement in the conflict.

Asked by The Intercept where he would rank the War Powers Resolution as an effective tool to nudge Saudi Arabia in the right direction, he demurred. “I wouldn’t rank these things. Look, I mean, we cannot dictate to Saudi Arabia their foreign policy, so we shouldn’t have illusions about that. We have to figure out where can we nudge and prod and push them in a direction that is better. So I think it’s a mistake to look at it as if there’s something we can do that would just like that change the way they interact,” he said. “My great hope for that region is that the Sunni and the Shia and the Persians and the Arabs can find some sort of peaceful resolution to their current disputes.”

In this photo taken Friday, Oct. 26, 2018, House candidate Sarah Smith poses for a photo in Seattle. Smith thought her campaign to unseat longtime Rep. Adam Smith might receive a lot more attention after little-known Alexandria Ocasio-Cortez upset a 10-term incumbent in New York last summer. Like Ocasio-Cortez, Sarah Smith is a young woman, a political newcomer and a Bernie Sanders-supporting Democratic Socialist challenging an entrenched fellow Democrat. (AP Photo/Elaine Thompson)

House candidate Sarah Smith campaigns to unseat longtime Rep. Adam Smith on Oct. 26, 2018, in Seattle, Wash.

Photo: Elaine Thompson/AP

Sarah Smith said that if Adam Smith backslides on Yemen, she’s willing to challenge him again, but she’s watching to see how he does as the chair of the House Armed Services Committee before making the decision. (Ocasio-Cortez endorsed Sarah Smith in 2018, and given Ocasio-Cortez’s higher profile, Smith noted, a second endorsement could mean that the challenge would pose a bigger threat.) “I’m not an opportunistic person. I’m just a calculated person. And so if he says he’s as progressive as he is, and if he makes all these promises on the campaign trail, I will be as supportive as I can be, as long as he is meeting his end of the bargain,” she said. “If he fails to meet his obligation, I’m going to make notes of every single time he’s failed and I’m going to challenge him again.”

One area Sarah Smith tried but did not succeed in pushing Adam Smith last year was the Stop Arming Terrorists Act, which would bar the Pentagon from arming three militant groups with a presence in Syria, including Al Qaeda and the Islamic State. (The Pentagon has armed Syrian rebels on the condition that their weapons be used only in the fight against ISIS, and the assertion that the U.S. has actively armed terror groups in Syria has little basis in fact.) The bill was introduced by Rep. Tulsi Gabbard, D-Hawaii, and co-sponsored by a small bipartisan group of lawmakers, including Khanna and Rep. Barbara Lee, but Adam Smith declined to co-sponsor it. “He’ll talk about, ‘Oh, I’m so progressive, I’m working with Ro very closely on this. It’s abhorrent what we’re doing in Yemen,’” Sarah Smith said of her former opponent, “but if you push him on any other bill beyond that, he won’t talk about it, radio silence, or he’ll have a million excuses. He is the excuse king.”

Adam Smith, though, said that his position on Yemen has nothing to do with Sarah Smith. Asked about her contention that his resistance to the Stop Arming Terrorists Act suggested weakness on his willingness to confront Saudi Arabia, he took a swipe at her residence, which sits just across the district. “I’m happy to talk about the issue, but I really don’t care what that one individual is going to say. She’s not even actually a constituent,” he said.

Ryan Grim is the author of the forthcoming book We’ve Got People: The Rise of a New Force in American Politics. To get an email when it’s released, sign up here.