House Republicans unveiled legislation late Tuesday night that included multi-year extensions of tax credits for solar and wind.

The credit extensions were attached to a broad set of spending measures as part of a negotiation with Democrats over lifting the ban on exports of U.S. crude oil.

Rhone Resch, president of the Solar Energy Industries Association, predicted in November that solar tax credits would likely be added to any deal around lifting the oil export ban. He called it "our best opportunity."

“Democrats are saying, 'We need to get something for it,' and the White House is chiming in too,” said Resch.

This month, Republicans demanded an end to the 40-year-old ban as part of a legislative tax and spending package that would fund the government through next fall.

Although many Democrats oppose ending the ban, they saw it as an opportunity to demand extensions of the Investment Tax Credit (ITC) for solar and the Production Tax Credit (PTC) for wind.

Yesterday afternoon, Democratic leaders said they would only support the Republican proposal if renewable energy credits were added to a tax or spending bill.

"We have 2 paths: 1. Pair oil export ban with policies to reduce carbon emissions; 2. Pass gov't funding without oil/renewables," tweeted Senator Harry Reid yesterday afternoon.

In 1975, Congress made it illegal for domestic drillers to ship crude out of the country. The export ban was designed to protect America from volatile oil prices in the wake of the Arab Oil Embargo. As U.S. production dwindled over the proceeding years, the policy was not contested.

Today, America is a leading producer of crude -- and drillers argue they should be able to export oil as an incentive to expand production.

Some see the tradeoff as a good deal.

"An oil-exports-for-renewables-tax-credits deal looks likely to be a win-win. Removing the oil export ban is good policy. Supporting zero-carbon energy innovation, including through appropriate deployment subsidies, is good policy," wrote Michael Levi, a senior fellow at the Council on Foreign Relations, in a recent analysis of the deal.

Last night, House Speaker Paul Ryan unveiled an omnibus spending bill that would lift the ban, while also extending solar and wind tax credits for two years.

The PTC -- a 10-year, 2.3-cent per kilowatt-hour credit -- would be extended through 2020. After December of 2016, the credit would be cut each year until it fully expired in 2020.

The ITC -- a 30 percent credit for utility, commercial and rooftop solar installations -- would get phased down through 2022. The credit would stay at 30 percent through 2019, and then fall to 26 percent in 2020. It would drop to 22 percent in 2021 and 10 percent in 2022. The bill also offers a commence-construction clause that would extend the credit to any project in development before 2024.

"The extension to the federal ITC is without question a game-changer for U.S. solar's growth trajectory. Between now and 2020, the U.S. solar market is poised to see a number of new geographies open up with a 30% ITC, within both distributed and utility-scale solar," said Cory Honeyman, a senior solar analyst at GTM Research.

The House and Senate will likely vote on the package Thursday night or Friday morning.

Although Democrats have signaled their willingness to support the deal, House Speaker Nancy Pelosi told Bloomberg that broad agreement wasn't guaranteed -- even with strong extensions of renewable energy credits.

Opponents see lifting the ban as a massive subsidy to oil producers and an environmental risk. In an op-ed this week, climate activist Bill McKibben explained why so many progressive environmentalists opposed a change to the law.

"What makes the plan to lift the ban especially galling is that the administration and congressional Democrats insist they’re getting a reasonable deal because the Republicans will concede tax breaks for solar and wind producers in return. But the logic of the Paris accords -- with their theoretical commitment to a world that will warm just 1.5 or 2 degrees -- means that we don’t get to keep making this kind of tradeoff," wrote McKibben.

Speaker Ryan assured reporters that he would get the votes to pass the package.

"I am not going to predict how the vote count will go down," Ryan said this morning during a press event. "Look, in negotiations like this, you win some, you lose some. Democrats won some, they lost some, we won some, we lost some. At the end of the day, we are going to get this done."