HALIFAX—Foreign leaders gathered in Nova Scotia this past weekend to talk high affairs of state, matters of war and peace—and what to do with a problem like Donald Trump.

The Halifax International Security Conference is one of the first opportunities for world leaders to huddle and exchange views on the American election. The shock results and the ambiguity of what Trump would do with his unexpected ascendency to power meant the prevailing mood of the world’s diplomats, academics, and politicians is one of utter uncertainty.

Many of the attendees reflect a pro-NATO, bipartisan Western order that has held together since the end of World War II, and they gathered for one of the calendar’s most important national-security conferences. The hundreds who met in Halifax—the experts, the experienced, the policy veterans—might have been dismissed by Trump during his campaign as so-called globalists or the “elite.”

But now many of them will be called on by their nations to fix the world’s challenges: the mass slaughter of civilians in Syria by Russian and Assad regime forces; the reemergence of nationalism; and the dangers of various cyberthreats.

Trump would have been a punchline when the annual Halifax summit gathered here last year—the serious money was on Jeb or Marco Rubio or Hillary. But the predictions and assumptions of these diplomats, ministers, and heads of state were shattered two weeks ago when Trump defied expectations to become the president-elect of the United States—and in turn, sent shudders down the spine of the leaders gathered here.

The shadow of Trump cut through every issue, as politicians like former Democratic Party Chairman Howard Dean intermingled with a crowd that featured National Security Agency chief Michael Rogers, retired Gen. John Allen, and former chairman of the British Joint Intelligence Committee Lillian Neville-Jones.

“There’s a whole series of threats to our stability. What the election of Donald Trump will mean for that stability is of course the newly-emergent central topic of every discussion,” Democratic Sen. Chris Coons told The Daily Beast.

Trump is no longer a joke to them, but instead a cause for profound alarm—especially his pronouncements on the NATO alliance, his talk of torturing prisoners, and his willingness to improve America’s relationship with Russia.

The Trump anxiety is most profound from countries in Eastern Europe who are terrified that Trump’s will usher in an era of Russian dominance and a resultant decline in their freedoms and independence.

“From my conversations with them, they’re very nervous. There have been mixed messages, obviously, and they’re continuing to get enormous pressure from Putin and the Russian propaganda machine,” Sen. John McCain, chairman of the powerful Senate Armed Services Committee, told The Daily Beast. “We don’t really know exactly what President Trump will do. Some of it depends on who his selection for Secretary of State and Secretary of Defense are.”

In the halls of the Halifax Westin, officials from countries like Ukraine and Estonia hustled from meeting to meeting to take the temperature of American support in this new age of Trump. Trump’s election has ushered in a moment of uncertainty for America’s allies. Will he withdraw from Asia? How will he address the Iran nuclear deal? Will he recognize the illegal Russian annexation of Crimea?

“There is a strong concern among many in Congress about any attempt by Trump to dramatically change our policies towards Russia, particularly with regard to recognizing [Putin’s] illegal occupation or his intervention in Syria on behalf of Assad,” Coons added.

The conference, which is sponsored in part by NATO, was particularly focused on what Trump’s election would mean for an alliance which has existed for nearly 70 years. During the campaign, Trump had suggested that the United States might want to distance itself from the organization—a major red flag for the diplomats and politicians assembled here.

“I think NATO may be obsolete,” Trump said in a March interview, adding that he would “certainly look at” getting rid of it.

But the conference’s participants are staying optimistic at what they see as positive developments by Trump since Election Day. In fact, as the conference was underway, NATO Deputy Secretary General Rose Gottemoeller announced that Trump and Secretary General Jens Stoltenberg had spoken by phone.

“Both agreed that we have work to do in the NATO alliance… but that we also have important missions going forward.”

Both Congressional and foreign leaders are trying to tread a fine line—not to needlessly antagonize Trump, but also to anticipate standing up to him at worthwhile moments.

“I believe that there’s every opportunity for us to work together. The approval rating of Congress is 14 percent,” McCain said. “It would be far better for all of us if we gave the president a honeymoon, and worked together, presented him with things like tax reform [and] a good solid defense bill.”

But McCain, who led the conference’s largest Congressional delegation ever, is also beginning to show flashes of the ‘maverick’ reputation that he developed during the George W. Bush administration for bucking the Republican Party on certain issues. In this administration, McCain said he will push back on issues such as torture—he had spent more than five years being tortured as a prisoner of war in Vietnam.

Asked about Trump’s pledge to bring back waterboarding and “much worse” interrogation techniques, McCain’s response was fierce and adamant. There would be no “honeymoon” for that.

“I don’t give a damn what the president wants to do,” McCain said, pointing out that he helped passed legislation last year that prohibits torture. “We will not waterboard. We will not torture people.”

Ultimately, however, the assembled leaders were trying to find a silver lining in the American elections, which in some ways was a rebuke of the pro-Western, democratic ideals that are the cornerstone of the NATO alliance. Sen. Tim Kaine, who was Hillary Clinton’s running mate, tried humor on for size, while receiving an award from the conference.

“A few years ago I went to a fortune teller, and she told me I was going to win something very big in November of 2016,” Kaine joked, upon receiving the award, to peals of laughter. But he quickly turned serious to point out a major positive that is missed in the negative news cycles of this year.

“With the ceasefire arrangement in Colombia, in the civil war between Colombia and the FARC, [North and South America are] two continents without war for the first time in recorded history,” Kaine said.

Alliances are more important now than they were 70 years ago, before the Marshall Plan was implemented and the Truman doctrine was described and NATO was formed, the senator argued, adding, “and that is why it is so important that we gather here.”