Chile on Wednesday canceled the international economic conference it was supposed to host next month because of mounting civil unrest.

U.S. President Donald Trump had hoped to sign a phase 1 trade deal with China at the Asia-Pacific Economic Cooperation summit, which had been scheduled for Nov. 16-17.

Chile also pulled out as host of the COP25 climate summit in December.

“This has been a very difficult decision, a decision that causes us a lot of pain, because we fully understand the importance of APEC and COP-25 for Chile and for the world,” President Sebastian Pinera said in a statement issued from La Moneda palace in Santiago.

“Our main concern is re-establishing public order, our citizens’ safety and social peace along with pushing through a social agenda to respond to the main demands of our citizens.”

The government declared a state of emergency this week in most of the country’s major cities as a result of riots, arson and protests over inequality in South America’s wealthiest nation. Some 7,000 people have been arrested and at least 18 deaths have been reported, with dozens more maimed in clashes with police.

Business losses are estimated at $1.4 billion.

Some 1 million people participated in a peaceful march during the weekend in Santiago, but smaller protests elsewhere have turned violent. The march was the largest since Chile restored democracy in 1990. The unrest was sparked by a 4-cent increase in public transportation fares.

Trump had been planning to meet with Chinese President Xi Jinping during the summit to sign the first step in a more comprehensive trade agreement aimed at ending the 16-month-old trade war. How and when the two leaders would meet was not immediately clear. The U.S. on Monday said it was considering an extension of tariff exemptions on $34 billion in Chinese goods.

The White House had no immediate comment.