Then about three years ago, I started to notice that green energy programs—the strong ones that are needed to lower global emissions fast—were increasingly being challenged under international trade agreements, particularly the World Trade Organization’s rules.