Alaskan lawmakers are finally about to receive a prize they’ve coveted for decades: permission from Congress to open up sections of the pristine Arctic National Wildlife Refuge in Alaska to oil and natural gas drilling.

The Republican tax reform bill, which contains language that directs Congress to conduct lease sales for energy development in the refuge, cleared the House on a party-line vote Tuesday and will likely pass the Senate.

Ryan mentions ANWR opening in the tax bill and some members working on issue since he was in 2nd grade. Alaska rep Don Young pumps his fist in the air and yells "yes." — Casey J. Wooten (@Casey_J_Wooten) December 19, 2017

To legislators from Alaska, this is a chance to make the state more economically resilient and refill Alaska’s Permanent Fund, which has been paying shrinking dividends from oil and gas revenue to Alaskans in recent years.

But time after time, Alaskan leaders have been stymied — as environmentalists have made blocking drilling in ANWR a rallying cry and Congress has offered tepid support at best and outright hostility at worst.

Now after nearly 40 years, the Alaska delegation — led by Republicans Sen. Lisa Murkowski and Rep. Don Young, currently the longest-serving member of Congress — is about to achieve this goal.

The legislation is attached to the Republican tax reform plan, and after months of horse-trading, Republicans have secured the votes in the Senate to pass the bill.

House members shook hands and fist-bumped with @repdonyoung on the floor after the tax vote, congratulating him for winning on ANWR. After 44 years, one of his biggest victories. — Liz Ruskin (@lruskin) December 19, 2017

Crucially, ANWR would add revenue to the tax reform package, which slashes taxes for corporations and the wealthy.

The Senate Budget Committee directed the Senate Energy and Natural Resources Committee to come up with $1 billion in revenue to help close the budget deficit. Were ANWR to be to leased oil and gas drillers, the Congressional Budget Office estimates it would generate $5 billion over 10 years for the federal government.

“It would generate substantial revenue for every level of government,” Murkowski said.

But as Vox’s Dylan Matthews reported, the tax plan overall would add $1.5 trillion to the deficit over 10 years; ANWR would take a tiny step toward closing that gap.

With her support, Murkowski helped cement the fate of the first tax reform package in 30 years, trading away her backing of the Affordable Care Act (she was one of three senators to torpedo repeal of Obamacare earlier this year) in favor of the prospect of extracting oil from the arctic refuge.

I joined a public mtg. of Senate/House conferees on the Tax Cuts & Jobs Act, emphasizing my support for this bill that allows access to a small portion of the non-wilderness 1002 Area to responsible energy development & benefits our families & businesses https://t.co/5lOCNB09RQ — Sen. Lisa Murkowski (@lisamurkowski) December 14, 2017

But there are several catches: Low oil and gas prices mean that drillers aren’t hurting for new wells. And not all Alaskans are on board with opening up ANWR, while environmental groups and Democrats are gearing up to fight it every step of the way.

“Our battle here is to make sure it is never opened,” said Sen. Edward Markey (D-MA) at a rally in October. “We think that big oil is going to get another big black eye.”

Let’s walk through the return of this familiar battle, and why Alaskan lawmakers are about to declare victory.

ANWR has been a central fight of environmental politics for years

Long before environmentalists and the fossil fuel industry traded blows over the Keystone XL pipeline and hydraulic fracturing, ANWR was the definitive issue dividing them.

The case for establishing the refuge was first laid out in the journal of the Sierra Club in 1953, and groups ranging from the Natural Resources Defense Council to the Audubon Society have all campaigned and litigated against Alaska’s attempts to allow drilling in ANWR for decades.

One of the last untouched places on earth is about to be given away to the oil industry. #ProtectTheArctic #ArcticRefuge pic.twitter.com/ISGYyrtD7a — CAP Energy Policy (@CAPenergypolicy) October 6, 2017

The push for drilling has also spanned generations of Alaskan politicians. Murkowski’s father, Frank Murkowski, added pro-drilling language into a Senate budget in 1995 that was vetoed by then-President Bill Clinton.

The 19 million-acre refuge, managed by the US Fish and Wildlife Service, was created in 1960 and remains the largest wildlife refuge in the United States. It’s home to polar bears, musk oxen, and migratory birds from six continents, and is the calving ground for the porcupine caribou. There are no roads and fewer than 500 people living in or near the refuge.

In 1980, President Jimmy Carter signed the Alaska National Interest Lands Conservation Act, expanding ANWR and opening the door to drilling in a 1.5 million-acre region of the refuge. However, there was a snag: Drilling would require an environmental impact study and approval from Congress.

Leaving the fate of oil drilling in ANWR to lawmakers has let this issue drag out for decades as support and opposition to drilling waxed and waned. Environmentalists have managed to successfully persuade Democrats (and some Republicans) to defend it.

But without definitive legislation supporting drilling, and without any rulings declaring ANWR completely off limits, the proposal has remained in limbo.

Why Alaska wants to open up ANWR so badly

Every October, each Alaskan who has been in the state longer than one year gets a check for around $2,200, a dividend from the state’s $61 billion Permanent Fund. The fund is larger than any private foundation, endowment, or union pension trust, and is the largest sovereign wealth fund in the United States.

The money for the Permanent Fund comes from oil and gas production in the state. Alaska residents are paid a dividend from earnings on the fund, not the principal. That means the dividend check can go up or down, even to zero, depending on the fortunes of the state’s energy industry.

In particular, the money is generated from the Trans-Alaska oil pipeline, which provides the state with 85 percent of its budget. Alaska does not have a state income tax or a sales tax, so the bulk of the revenue has to come from energy.

At its peak in the 1980s, the pipeline transported more than 2 million barrels of oil per day. But oil production is now a quarter of that, so the state is facing increasing pressure to raise cash.

The state’s budget deficit is now at $3.7 billion. And this year’s dividend payment from the Permanent Fund was $1,100 — about half of what Alaskans have received in previous years, drawing the ire of many in the state.

That’s why Alaskan lawmakers have renewed their push for ANWR drilling.

“This is not so much about the oil industry; it’s really about Alaska,” said Athan Manuel, director of the lands protection program at the Sierra Club. “The state of Alaska has been salivating for this kind of stuff.”

But it’s not clear how much oil is really there. And oil companies aren’t that interested in it.

Though Alaskan politicians have long painted ANWR as a rich oil field just waiting to be exploited, it’s difficult to say just how much oil really is there.

There’s only been one exploratory well drilled in the territory, back in 1986, and the drillers haven’t disclosed what they found, which some analysts have taken to mean that there’s less oil there than hoped.

USGS estimated in 1998 that there is between 4.3 billion and 11.8 billion barrels of oil in the 1002 area, a rather vast margin of error.

The federal government has also banned seismic testing in ANWR to measure oil deposits. The process involves setting off explosives or rattling the earth with 40,000-pound thumper trucks and measuring the vibrations to detect underground reservoirs. The Trump administration is now taking steps to allow this technique in the refuge.

However, other parts of northern Alaska have yielded major oil finds, and the state has extracted oil there for more than 50 years, currently producing about 500,000 barrels of crude every day, according to Kara Moriarty, president and CEO of the Alaska Oil and Gas Association.

“It’s a very mature basin, but the future is incredibly bright,” she said, adding that oil finds in Alaska “could be producing for at least another 40 years plus.”

Moriarty also noted that the oil industry isn’t planning to develop the entire swath of 1002 lands, keeping most of its activities in a stark, treeless 2,000-acre region on the coastal plain that is far away from the majestic vistas that often illustrate ANWR discussions.

“It’s a very sensitive environment; we’re very mindful of that,” she said. “But it’s not the mountain and lake pictures that are often used. That area is permanently set aside and can never be developed.”

But environmental groups don’t think it’s possible to develop energy in the Arctic without damaging it, even on a remote and limited stretch of land. “Even if they don’t spill a drop, they are industrializing a wilderness area,” said the Sierra Club’s Manuel.

At the same time, the energy landscape has changed radically since drilling in ANWR became a possibility more than 30 years ago, with US crude oil production reaching record highs and prices holding below $50 a barrel, driven largely by the shale oil and gas boom.

Now with a glut of fossil fuels in the US and around the world, oil and gas companies are offering muted support for new drilling in the Arctic.

“If the 1002 area was authorized for leasing, we would consider it against other opportunities in our portfolio, just as we do with exploration opportunities worldwide,” said Daren Beaudo, a spokesperson for ConocoPhillips, in an email. “That being said, we see tremendous potential in National Petroleum Reserve-Alaska and remain focused on our projects and exploration plans in the Reserve.”

Frank Wolak, an economics professor and director of the program on sustainable energy at Stanford University, said current market conditions mean that drilling in the Arctic, which tends to be more expensive and difficult than drilling in the lower 48, doesn’t make much sense when energy prices are poised to stay low.

Environmental groups have also been preparing for decades to fight Arctic drilling if Congress ever gives it a green light.

“It’s going to be litigation like you’ve never seen from the environmental community,” Wolak said. “Why take that on when oil prices are at their current levels?”

Alaskans who are close to ANWR are divided on it

Bernadette Demientieff, a member of the Gwich’in tribe and executive director of the Gwich’in Steering Committee, said her tribe considers the coastal plain of the refuge to be sacred and that it should be protected from drilling.

The tribe historically followed caribou herds in the region, which spend part of the year on the coastal plain, but have faced increasing pressure as average temperatures in the region have risen.

“Many of our people now have to travel hundreds and hundreds of miles just to hunt the caribou we have depended on,” Demientieff said.

Now the tribe is concerned that caribou herds will decline further with the advent of drilling, just as herd numbers have fallen in other areas of Alaska’s north slope where mineral extraction is permitted.

The prospect of losing a valuable food source and cultural element would be devastating to a people that are already facing immense environmental pressures.

“Not only our we dealing with climate change, it’s also food security, it’s also our identity,” Demientieff said.

But other indigenous groups have thrown their weight behind drilling proposals.

In September, the Voice of the Arctic Iñupiat, a group representing indigenous people in the region, came out in favor of energy development in ANWR.

“Collectively, we are concerned about the future of our communities and, as of today, we stand together, with our members from Kaktovik, in support of ANWR development as part of the economic solution for the Arctic Slope region,” John Hopson Jr., mayor of Wainwright, Alaska, and vice chair of Voice of the Arctic Iñupiat, in a press release.

He cited the need for economic development in the remote region and the potential for improving schools, sanitation systems, and clinics with revenue from drilling.

Murkowski will have to walk a fine line here. She owes her political life to tribal groups in Alaska who mounted a write-in campaign for her after she lost her primary to Tea Party candidate Joe Miller in 2010, and the ANWR issue is threatening to divide Alaska natives.

This is going to be a long fight

The divide among Alaskans over the fate of ANWR has an analog on Capitol Hill.

Washington Sen. Maria Cantwell scuttled the last major effort to open ANWR to drilling back in 2005, when she blocked Alaska Sen. Ted Stevens, then the longest-serving Republican in the Senate, from tacking on drilling to a military spending bill with a filibuster.

"Destroying a national wildlife refuge is not the answer to our nation’s energy problems," she said at the time.

Cantwell is now the ranking member of the Senate Energy and Natural Resources Committee, where she sits right next to Lisa Murkowski.

The two senators have worked together on energy legislation, but on ANWR, they couldn’t be further apart.

On the Senate floor in October, Murkowski reiterated her case for drilling in the Arctic and called arguments against it “stale.”

We will balance the potential impacts of development, and that's why we have not avoided environmental reviews. We will not sacrifice wildlife for the sake of development. There is no question that development & environmental protection can and do exist in Alaska. — Sen. Lisa Murkowski (@lisamurkowski) November 15, 2017

However, passing the tax bill doesn’t guarantee that companies will drill in ANWR. The language of the legislation only directs the government to hold mining and drilling lease sales for the refuge. If no one buys, no one drills.

A future Congress could also designate the 1002 region a wilderness area, effectively ending the prospects for drilling altogether.

Legal action could easily stall the permitting process, which requires a public comment period at almost every stage of development, from awarding leases to siting to drilling, creating openings for lawsuits.

“We’re expecting litigation at each and every step,” said Moriarty. “If the budget resolution passes, I’m not sure you’d see production” before the end of Trump’s potential second term.

And even if drillers clear those administrative barriers, actually finding suitable drilling sites can be a difficult process, since oil companies can only explore for oil in the winter when the Alaskan ground is hard enough to support ice roads.

That means it would take upward of a decade before any oil from ANWR starts coursing through the Trans-Alaska pipeline.

“This is something that would be a very long-term play,” Moriarty said.

Correction: An earlier version of this article said the Alaska Permanent Fund is larger than any pension in the United States. In fact, it is larger than any union pension trust, but not larger than every pension.