WASHINGTON (Reuters) – Republican and Democratic leaders of the U.S. Senate hoped to vote on Wednesday on a $2 trillion emergency package to alleviate the devastating economic impact of the coronavirus pandemic, but found themselves fending off critics from the right and left who threatened to hold up the bill.

Top aides to Republican President Donald Trump and senior senators from both parties said they had agreed on the unprecedented stimulus bill in the early hours of Wednesday morning after five days of talks.

The massive bill includes a $500 billion fund to help hard-hit industries and a comparable amount for direct payments of up to $3,000 apiece to millions of U.S. families. It is intended to flood the economy with cash in a bid to stem the impact of a pandemic that has killed more than 900 people in the United States and infected at least 60,000.

Several Republican senators said the bill needed to be changed to ensure that laid-off workers would not be paid more than they earned on the job.

“This bill pays you more not to work than if you were working,” Republican Senator Lindsey Graham, a close Trump ally, told a news conference.

Democrats scoffed in response, noting that employees cannot collect unemployment if they leave their jobs voluntarily.

“Why would the senators hold up this really important bill … because they resent people at the low end of the spectrum who have lost their jobs, from getting $600?” House of Representatives Speaker Nancy Pelosi asked on CNN.

Related Coverage

Independent Senator Bernie Sanders, who is running for the Democratic presidential nomination, said he was prepared to block the bill if Republicans did not drop those objections.

The disputes clouded optimism that the bill could become law quickly. Administration officials said Trump would definitely sign it into law if it passed both the Republican-led Senate and Democratic-majority House.

“Today the Senate will act to help the people of this country weather this storm,” Senate Majority Leader Mitch McConnell said.

Senate Democratic leader Chuck Schumer said his party was willing to pass the bill as quickly as possible.

“Help is on the way. Big help. Quick help,” he said.

It was unclear, however, how quickly the bill would get to Trump’s desk.

A vote had not been scheduled in the Senate by Wednesday evening. Pelosi said the House would give its members at least 24 hours’ notice before voting on the relief bill.

It was also not clear whether House members would have to return to Washington for the vote, although if members agreed, the bill could pass by a voice vote with very few of them in the House chamber.

BIGGEST BAILOUT

The legislation will also provide $350 billion for small-business loans, $250 billion for expanded unemployment aid and at least $100 billion for hospitals and related health systems.

The rescue package would be the largest ever approved by Congress, and follows two others that became law earlier this month. The money at stake amounts to nearly half of the $4.7 trillion the U.S. government spends annually.

Investors were cheered by the news or the deal. On Wall Street, the benchmark S&P 500 .SPX rallied for a second straight day, closing up 1.15%.

Some high-profile opposition to the bill came from Schumer’s home state.

New York Governor Andrew Cuomo said the $3.8 billion allocated to his state would not cover the tax revenue it stands to lose from reduced economic activity. New York accounts for roughly half of all U.S. coronavirus cases.

“That is a drop in the bucket,” Cuomo said at a news conference.

Pelosi said she was sympathetic to Cuomo and other state officials, but wanted a rescue package to move on. “We (Congress) do have to do more, but that would be no reason to stop this step that we are taking,” Pelosi said on CNN, adding that she hoped the Federal Reserve would do more for states.

The governors of at least 18 states, including New York, have issued stay-at-home directives affecting about half the U.S. population. The sweeping orders are aimed at slowing the pathogen’s spread, but have upended daily life as schools and businesses shutter indefinitely.

(Interactive graphic tracking global spread of coronavirus: open tmsnrt.rs/3aIRuz7 in an external browser.)