Lawmakers have struck a final farm bill deal that scraps a plan backed by House Republicans and President Trump to add new work requirements for recipients of food stamps.

The House and Senate have been deadlocked over multiple issues in the bill, including provisions in the House bill that would add new work requirements for older food stamp recipients and for parents of children age 6 and older.

But those provisions have been stripped in the compromise package, Sen. Pat Roberts (R-Kan.), chair of the Senate Agriculture Committee, confirmed Thursday.

The farm bill deal was confirmed Thursday by House and Senate lawmakers from both parties. If finalized, it would break a months-long congressional impasse over legislation that doles out billions of federal dollars in food aid, agriculture subsidies and conservation funds.

Roberts told reporters that the House bill could not have passed the Senate without changes. “You have to have something that will pass the Senate,” he said. “We took a more comprehensive approach.”

But the deal faced immediate opposition from some of the most conservative House Republicans.

Rep. Mark Walker (R-N.C.), who leads the Republican Study Committee, signaled his potential opposition to the agreement, citing conservative support for stricter work requirements.

“House conservatives, the President, and the vast majority of Americans support policies that encourage work and help lift people out of poverty,” Walker wrote on Twitter. “As I’ve said for months, those provisions have to stay.”

The White House has not yet signed off on the compromise, Roberts said.

Despite some conservative opposition, the compromise is likely to attract bipartisan support in the House. GOP leadership intends to give lawmakers time to review the package before moving forward, according to aides who spoke on the condition of anonymity because they were not authorized to discuss the plans publicly.

Liberal groups have vehemently opposed the proposed restrictions on food stamps, which they say are needed for people in poverty. Between 800,000 and 1.1 million households would have faced food stamp benefit cuts under one of the House Republican proposals, according to a study by the Mathematica Policy Research, a policy research organization.

Under current rules, most adults are required to work to receive food stamps. But House Republicans’ farm bill would have forced states to impose work requirements on those ages 49 to 59, an approach rejected by the Senate. The Senate also rejected the proposal to force states to impose work requirements on parents with children ages 6 to 12.

The White House cannot on its own force states, which administer the food stamps program, to enact either change. But the Trump administration has signaled its intention to cut food stamps without approval from Congress. This year, the Agriculture Department floated weakening the waivers it gives states to temporarily suspend some food stamp work requirements — something it could propose through regulations and without approval from Congress. Those waivers allow states to exempt food stamp beneficiaries from certain requirements if they live in areas with high levels of unemployment or there’s a lack of available jobs.

“Too many states have asked to waive work requirements, abdicating their responsibility to move participants to self-sufficiency. Past decisions may have been the easy short-term choice, but USDA policies must change if they contribute to a long-term failure for many [food stamp] participants and their families,” Agriculture Secretary Sonny Perdue said in a news release this February.

Losing the work requirements would mark a setback for conservatives who long have promised to make cuts in social programs if given control of government. But despite holding both chambers of Congress, Republicans have fallen short of the large-scale restructuring of social programs they pushed for.

The work requirements were included in a version of the farm bill the House passed in June, as Republicans overcome unanimous opposition from Democrats. A week later, the Senate overwhelmingly approved a bipartisan version of the bill that scrapped the work requirements.

Many Senate Republicans approved of the work requirements in principle, but they knew the bill — which contains agricultural subsidies that are a top priority for farm-state lawmakers from both parties — needed support from Democrats to move through the Senate.

Trump is August called on the Senate to adopt the House work requirements.

“When the House and Senate meet on the very important Farm Bill — we love our farmers — hopefully they will be able to leave the WORK REQUIREMENTS FOR FOOD STAMPS PROVISION that the House approved,” the president wrote on Twitter.

But it appears Trump’s call has been rebuffed.

The four lawmakers leading the negotiations — Sens. Roberts and Debbie Stabenow (D-Mich.), the leaders of the Senate Agriculture Committee, as well as Reps. K. Michael Conaway (R-Tex.) and Rep. Collin C. Peterson (D-Minn.) — announced Thursday that they had an agreement in principle.

Lawmakers faced pressure from farmers and ranchers to get a deal done, particularly amid a steep decline over the past several years in farm incomes as commodity prices have sagged, said Dale Moore, executive vice president of the American Farm Bureau Federation, an industry group.

Farm-state Sen. Jon Tester (D-Mt.) said he was encouraged by news that a deal had been reached and had won Stabenow’s support.

Erica Werner contributed to this report.

Jeff SteinJeff Stein is a policy reporter for The Washington Post. Before joining The Post, Stein was a congressional reporter for Vox, where he wrote primarily about the Democratic Party and the left. In 2014, he founded the local news nonprofit the Ithaca Voice in Upstate New York. Follow