Congressional leaders in both parties signaled they were working on a deal to extend the payroll tax cut and unemployment benefits for at least two months, while also agreeing on a spending bill that would avert a government shutdown.

Lawmakers worked into the evening Thursday and gave encouraging signs that the partisan bickering may be cooling down at last as voters grow increasingly impatient with the gridlock that has characterized Capitol Hill this past year.

Negotiators have agreed on a $1 trillion spending blll to fund government operations through September 30.

However, a deal on the payroll tax cut remained unsettled as of Friday morning, especially how to pay for the cost of extending this year’s 2 percentage point cut in Social Security and Medicare withholding taxes from 6.2 to 4.2 percent beyond December 31. Lawmakers also need to agree on how to pay for extending federal emergency unemployment insurance benefits, and the “doc fix” that would keep Medicare reimbursements to physicians from plummeting 27 percent.

“We hope that we can come up with something that would get us out of here at a reasonable time in the next few days,” said Senate Majority Leader Harry Reid, D-Nev., according to Politico.

He dropped his hold on the spending bill, which had been used as a bargaining chip to encourage Republicans back to the bargaining table. Funding for government operations could run out unless the spending bill is quickly approved and signed into law by midnight Friday.

Congressional Democrats and the Obama administration have dropped their demands for a surtax of 3.25 percent on income over $1 million to pay for the cost of extending and expanding the payroll tax cut to 3.1 percent. House Republicans passed a bill Tuesday evening to extend the current level of payroll tax cuts, offsetting the cost in part by extending a pay freeze for federal employees, cuts in the federal workforce, means testing of retirement benefits, accelerated approval of the controversial Keystone XL pipeline, reduction in the maximum length of unemployment benefits, and other provisions distasteful to Democrats (see House Passes GOP Payroll Tax Cut Extension Bill). President Obama threatened to veto the bill, but it failed to advance in the Senate on Wednesday before it ever reached his desk.

The compromise bill is likely to include some of the spending cuts in the Republican bill, and the two parties may be able to agree on some of the revenue generators such as auctioning off wireless spectrum. Depending on the amount they can agree upon, the deal may be enough to fund a two-month extension of the payroll tax cut, unemployment benefits and the “doc fix.”

Lawmakers appear to be ready for a compromise so they could head home for the holidays. “This is not the first time I’ve seen year-end work get knotted up,” said House Speaker John Boehner, R-Ohio. “But I think everyone just needs to step back and take a deep breath. I think there’s an easy way to untangle all of this. We just need to let the members do their job, and we need to let the two institutions do their work.”

The two parties also eventually need to agree on a way to extend a host of other expiring tax breaks, including the “patch” to the alternative minimum tax to prevent the AMT from applying to millions more taxpayers. But they may have to wait until after the holiday break and pass an extenders package retroactively.