After days of snags and delays, congressional leaders staggered toward completing a massive $1.3 trillion "omnibus" spending deal Wednesday, according to multiple Republican and Democratic sources familiar with the negotiations.

The monster-sized bill contains one of the largest spending increases in recent history, and is critical to avoid a government shutdown Friday night, when Congress' self-imposed funding deadline hits. Even if the expected deal is announced Wednesday, it would need rare unanimous agreement in the Senate to make it through the upper chamber in time to avoid a shutdown.

Here is where the omnibus stands, according to sources familiar with the draft:

ISSUES

Gun research. Wednesday afternoon, negotiators were finalizing a significant clarification to current law, stating that nothing prohibits federally-funded programs from researching gun violence. That amounts to a de facto change, after years where a rule known as the Dickey amendment was interpreted as banning such research.

Gun and school safety. Two bipartisan bills aimed at preventing violence in schools are in the omnibus draft. The Fix NICS Act uses carrots and sticks to increase the amount of data agencies send into the current background system. And The Student, Teachers and Officers Preventing (STOP) School Violence Act would authorize millions of dollars in grants to help schools increase security and learn how to better identify potential threats.

The wall and border security: The deal provides $1.57 billion for "physical barriers and technology." But, according to a Democratic source, just $641 million of that could go to barriers, and that would be restricted to see-through fences and levees; the funding could not be used to build a concrete wall. The vast majority — $1.3 billion — of the border security money is for technology, according to the Democratic source.

Immigration enforcement: The bill does not fund President Donald Trump's request to increase the number of detention beds and Immigration and Customs Enforcement officers.

Sanctuary cities: The omnibus does not defund so-called "sanctuary cities," something conservatives had hoped to see.

Health Care: The omnibus does not fund billions of dollars in subsidies for families who may have trouble paying doctor-office co-pays or deductibles. The president ended the subsidies, known as cost-sharing reduction or CSR payments, and asked Congress to decide their fate. Some argue that without them, premiums will spike 10-40 percent for certain groups of people. Others insist they are a giveaway to insurance companies. Regardless, they will not be funded.

Gateway tunnel: The compromise does not specifically fund the Gateway tunnel between New York and New Jersey, a project Trump has opposed that was a priority for lawmakers from the northeast. But, according to a Democratic source, it would increase funding to other programs which could then use that money for the Gateway tunnel, including Amtrak and other federal accounts.

Abortion: The bill continues current policies. Planned Parenthood would remain eligible for federal grants, and Trump's expansion of the Mexico City policy, which blocks U.S. funding for international organizations that discuss or perform abortions, would continue.

AGENCIES

Law enforcement: The F.B.I., D.E.A., U.S. Marshals and other law enforcement agencies will see a 3 to 5 percent increase in funding.

Military pay: The bill fully funds a 2.4 percent pay raise for troops.

Defense spending: The military will see a surge in funding of $61 billion for fiscal year 2018. That is the largest year-to-year defense spending increase in 15 years, according to a Republican source.



Veterans: An increase of $2 billion will go to veterans' hospital maintenance and backlogged construction projects.

2018 Elections and cyberwarfare: The bill adds another $307 million on top of the president's budget request for the F.B.I's work to secure the 2018 U.S. elections and fight Russian cyberattacks. An additional $380 million will go to states to help them protect their voting systems.

EPA: The Environmental Protection Agency retains its current funding. Trump had proposed a 30 percent cut in its budget.

The Census: As it approaches the 2020 survey, the U.S. Census will see a $1.34 billion increase in funding.

WHAT WE DON'T KNOW YET

Until the final legislation is posted, many issues remain unclear.

This spending package is seen as the last major legislation of the year, and lawmakers have been fighting to attach dozens of bills, from Veterans Administration reform to minor league baseball salaries to funding wildfire prevention.