Television producers with the White House press corps move their equipment out of the Melia hotel on Tuesday in Hanoi. (David Nakamura/The Washington Post)

What happens when the authoritarian ruler of North Korea checks into a hotel teeming with American journalists filing round-the-clock news reports?

The free press loses — or at least it did Tuesday after Kim Jong Un arrived a day ahead of his two-day summit with President Trump.

As Kim’s motorcade was barreling into Hanoi for the final leg of his nearly 70-hour journey from Pyongyang — which included a 65-hour train ride through China — authorities were scrambling behind the scenes to avert an all-out culture clash over the boundaries of free speech for a leader accustomed to an obedient state-controlled media.

Kim was staying at the Melia hotel tower in the heart of the city, but the hotel also happened to have been booked by the White House as the filing center for the traveling press corps to cover the summit.

Not long before Kim arrived, a notice was distributed to the press corps that the filing center would be moved to a separate site for the international press corps at the Cultural Friendship Palace.

A tweet from the Vietnamese government, complete with three megaphone emoji, confirmed the switch.

That left the U.S. press contingent scrambling to make the move. Television network producers had spent weeks setting up cameras, lights, monitors and other equipment shipped halfway across the world. A person with knowledge of the situation said the networks were told they could no longer do live shots from the Melia, although the correspondents booked to stay in the hotel were not told they had to leave.

“It doesn’t seem like there’s much choice, so I don’t know if anyone is objecting too hard right now — people are just figuring how to move their stuff,” said the person, who spoke on the condition of anonymity to discuss the sensitive situation. “I’m sure once it’s over, the bureau chiefs will try and find out what happened, since the Melia was charging many tens of thousands of dollars for the space.”

The press filing center on the seventh floor of the hotel featured a cavernous workspace with blue and gold carpet, hundreds of chairs at dozens of long wooden tables with name tags for major American media outlets, and water bottles and extension cords for the print and broadcast equipment necessary to cover the major media event.

As it became clear Kim would stay at the Melia, U.S. and foreign diplomats had privately expressed surprise that the White House was keeping with its plan to keep the filing center there.

The young dictator lives in near-constant fear of attempts on his life staged from inside or outside North Korea, making the regime highly concerned about security precautions during the rare occasions he travels outside the country.

Once Kim set foot in the Melia Hanoi, a person inside the hotel said they witnessed a tense standoff between a North Korean official who yelled at Vietnamese security and hotel staff, demanding they tell journalists in the lobby not to take pictures or even look at the scene. One member of hotel management called the North Korean moves “unprecedented” and said he was forced to turn over control of the entire hotel to the North Koreans.

Margaret Talev, a White House reporter for Bloomberg News who is staying at the Melia, wrote on Twitter that security was tight in the hotel as Kim arrived: Guests were cleared from the lobby, and window shades were pulled down.

“Security forces prohibited us from taking pictures from inside the hotel though we could see (state?) camera rolling on him as his entourage came thru,” Talev wrote. “Guards were literally right up on us saying no cameras.”

The Vietnamese government informed the White House of the request for the press corps to vacate the Melia. It is not clear why summit organizers did not foresee the coincidence in advance and make the switch before both sides had checked in.

Like previous presidents, Trump travels with a 13-member press pool that typically stays in the same hotel when he is on the road; that group is scheduled to stay in his hotel, the JW Marriott, when Trump is in Vietnam on Tuesday and Wednesday nights. However, the press filing center is typically at a different location.

Outside the Melia, where police had cordoned off the street, reporters shot video and pictures of Kim’s arrival from down the block. A metal detector had been set up at the door a day earlier, and guests at the hotel were accompanied in and out by authorities.

Upstairs, the filing center went unused.