PARIS (AP) — Diplomats at UNESCO are hailing a possible breakthrough on longstanding Israeli-Arab tensions at the U.N. cultural agency.

Israel’s ambassador to UNESCO said the mood was “like a wedding” after member nations signed off on a rare compromise resolution Thursday on “Occupied Palestine.”

The document is still quite critical of Israel, notably its actions in Jerusalem and Gaza. But Israeli Ambassador Carmel Shama-Hacohen told The Associated Press that diplomats agreed to move the most controversial language to a non-binding annex and avoided a contentious vote.

The compromise, worked out in months of painstaking negotiations, was largely technical. But it was an unusual example of Mideast cooperation at UNESCO, which Israel has long seen as biased toward Arab nations — especially since it admitted Palestine as a member in 2011.

Other diplomats said they hope the compromise encourages the U.S. and Israel to reconsider their decision to quit UNESCO at the end of this year.

“It means that the spirit of dialogue is not broken,” UNESCO Director General Audrey Azoulay told The Associated Press. Since taking over in November, Azoulay has been working to clean up the agency’s reputation and shore up a budget gutted by geopolitical disputes.

The relief and optimism at UNESCO’s Paris headquarters after Thursday’s meeting were a far cry from the hostility that has for decades soured its discussions on Israel and the Palestinian territories, and hampered the agency’s efforts to protect cultural heritage or promote peace through school projects in the region.

The enthusiasm over what on the surface seems like a minor move is a reflection of the very low expectations for Israeli-Palestinian cooperation in the current climate.

The UNESCO negotiations notably hit trouble as deadly confrontations erupted in Gaza in recent weeks, said diplomats involved, who were not authorized to be publicly named discussing the closed-door negotiations.

The Palestinian, Israeli, Jordanian, U.S. and European Union delegations negotiated the compromise resolution, along with representatives of UNESCO leadership.

They notably decided to limit the official “Occupied Palestine” resolution to three short paragraphs, and attach multiple pages of complaints about Israeli policies and Arab claims on Jerusalem in an annex, which is made public but is not binding. And then they agreed to adopt it by consensus instead of a public vote.

“I’m more than happy” with the outcome, the Israeli ambassador said. “Confrontation is not the way. Nothing will be changed in Jerusalem or in Gaza by forcing Israel into a corner.”

The annex notably criticizes Israeli actions in east Jerusalem, captured by Israel in the 1967 Mideast war and claimed by the Palestinians as their capital. East Jerusalem is home to the city’s most sensitive Jewish, Christian and Muslim holy sites.

Time and again, past UNESCO resolutions infuriated Israel, notably with language seen as denying Jewish ties to Jerusalem, or referring to sites that are holy to Jews and Muslims solely as Palestinian.

Mounir Anastas, the Palestinians’ alternate permanent delegate to UNESCO, welcomed “so many efforts from all concerned parties and different delegations in order to enhance the dialogue and to reach a consensus.”

But he urged progress on the ground, notably allowing UNESCO delegations to visit historic sites in Jerusalem, allowing Palestinian youth groups into Jerusalem for education programs, and protection for media covering protests in Gaza.

The U.S. delegation said it “warmly welcomes the progress demonstrated here” and praised the “constructive spirit,” but wouldn’t comment on whether it could lead to a rethink of the pending U.S. withdrawal.

The U.S. stopped paying its UNESCO dues after Palestine joined in 2011 but continues to participate in agency activities for now. President Donald Trump announced in October that the U.S. would pull out at the end of 2018 because of perceived anti-Israel bias.