Cartel member must punish non-cooperation by hurting themselves. They have no legal way to enforce their agreements, but reducing the prices of their output will punish the cheater (and all the others). Saudi Arabia did this at the end of 1985. All the other members of OPEC had been cheating, while they supported the price of oil by producing less. Final, when their production got down to 25 percent of their capacity, the broke the cartel. That is, the started undercutting the others, taking away their business and producing more. The cut the price of oil in half and hurt all of them. Had they continued supporting the price, they would have had to cut their production to zero in another year and a half.
The problem for a climate agreement, like the problem for a cartel, is that for each country individually, cheating is profitable. In a cartel, cheating is selling more, and under a climate agreement, cheating is emitting more. In either case, the country that does not cooperate will benefit from the cooperation of all the others. And the country that cheats, gains from getting to emit more or sell more.
So a global climate agreement can be thought of as global climate cartel—a good cartel. Instead of supplying less of some commodity such as oil, its goal is to use less fossil fuel. There is a cost to cooperating, but if all countries cooperate, the benefits to each member country from the action of the cartel as a whole will exceed the country’s individual cost.
Unfortunately, cartels almost always fall apart because they have no good way to enforce their agreements. Fortunately, a climate agreement could use legal means to enforce its agreement. That is solution #2 listed above.
Because climate change is caused by a global externality, a climate cartel is necessary. So the only sensible thing to do is find a legal way to enforce the agreement. It need not be harsh, but must be effective. If it is, and countries know it's effective, it will almost never be needed.