As lawmakers scurried to keep the government open and head home for the holidays, they wrapped spending and tax deals into a costly measure that highlighted our nation’s mismatched energy policies.

Specifically, this monster bill extended and restored tax incentives for wind and solar power while lifting a ban on crude oil exports that began during Jimmy Carter’s presidency.

On the one hand, the private sector can keep generating a growing share of the nation’s electricity from renewable, free, and non-polluting resources. On the other hand, some oil that might have stayed in the ground just became more likely to be extracted and burned.

But the deal’s contradictory compromises won’t cancel each other out. Ultimately, the Republican-led Congress — which largely pledges its allegiance to Big Oil — wasted no time in helping the United States adhere to its commitments under the global accord sealed in Paris.

As more homeowners, drivers, industries, and utilities draw their power from the sun and the wind, catastrophic climate change will become less likely. And the long-term climate benefits of boosting wind and solar power for five more years will outweigh the potential climate pollution from allowing crude exports, Council on Foreign Relations energy expertMichael Levi predicts.

Currently, oil prices are so depressed due to a global glut that there’s little demand elsewhere for U.S. crude. If oil markets bounce back, the long-term climate consequences of this largely symbolic victory for Big Oil will probably be small.

Stretching renewable-energy credits out for another five years, however, will deliver major relief to the wind industry. The Production Tax Credit, its primary source of federal support, had been in limbo for most of the past two years.

Then there’s the solar energy Investment Tax Credit. Without the new tax deal, it would have expired at the end of 2016. Now it’s assured through 2022.

Wait. Many Republican lawmakers scoff at the notion of climate action and are trying to sabotage President Barack Obama’s Clean Power Plan. Why would they buttress renewable energy right after the Paris deal?

There are plenty of reasons.

Take job creation. The solar industry alone already employs 200,000 workers and anticipates bringing another 140,000 on board because of the tax credit’s extension. It also goes out of its way to hire veterans and plans on hiring 50,000 of them by 2020.

There’s also the shockingly good results of government support for these industries through the tax code, which in recent years has coincided with technological breakthroughs that are now slashing costs for turbines and solar panels.

Then, there’s vigorous public support for wind and solar energy, which is nearly as strong among Republicans as Democrats.

While letting solar tax credits lapse wouldn’t have short-circuited that part of the renewable boom outright, Rhone’s solar trade group predicted that it would have slowed things down, including the pace of job and investment growth.

Likewise, the wind industry — despite boasting about $20 billion worth of wind farms now under construction — feared falling off an “economic cliff” had Congress failed to restore the Production Tax Credit for multiple years.

Now the forecast for renewable energy looks sunny and bright, thanks to this green and dirty gift from Congress.