The agreement was a compromise wrestled out of countries with sharply conflicting interests by the oil-rich United Arab Emirates, hosting COP28 in the last days of the hottest year humans have recorded so far.