ALBANY — State leaders yesterday ruled out the possibility of a government shutdown today, but Gov. Paterson said he was giving lawmakers “a warning period” of two weeks before forging ahead with more contentious budget cuts.

An immediate nightmare shutdown scenario grew more remote as leaders in the narrowly divided state Senate appeared to assemble the 32 votes needed to pass emergency spending legislation before the clock strikes midnight tonight.

Senate Democratic Leader John Sampson of Brooklyn told senators privately over the weekend that the next round of week-to-week budget extenders would have enough support to be approved today, even if Republicans don’t lend a few votes.

“The extender bill will pass,” Sampson said after speaking at a breakfast hosted by the Metropolitan Council on Jewish Poverty. “We have the votes. We will pass the extender and we will continue.”

At least two Albany-area Republicans have said they will likely vote for the legislation to keep paychecks flowing to the state workforce, suggesting the budget bills will pass even if rogue Democrat Sen. Ruben Diaz Sr. (D-Bronx) carries out his threats to vote no.

“I assume there will be the votes to pass it,” said a Senate Republican source.

Sampson has also received assurances that Diaz would provide his crucial vote if the GOP failed to deliver, two Senate Democrats said.

“I have no doubt the governor’s budget extender will pass,” Assembly Speaker Sheldon Silver (D-Manhattan) told The Post. “I think John Sampson has the situation under control.”

Paterson sounded the alarm about a potential shutdown last week after Diaz, Senate Majority Leader Pedro Espada (D-Bronx) and Senate Minority Leader Dean Skelos (R-LI) signaled they would vote for a shutdown to force a resolution to the state’s 2-month-old budget stalemate.

Skelos and Espada backed off after Paterson revealed that although the legislation would contain $327 million in cuts to mental-health and human services, they involved largely noncontroversial reductions.

But Paterson said last night that after the next two weeks, he would force lawmakers to vote on cuts they haven’t yet agreed to in order to close the remainder of an estimated $9.2 billion budget.

“I’m going to have to start finishing these issues off,” the governor vowed.