WASHINGTON — A high-stakes Senate debate over immigration got off to a halting start Tuesday, with Republican and Democratic leaders immediately at loggerheads over how to move forward and President Trump warning this was the “last chance” to extend protections to “Dreamer” immigrants.

Trump issued the warning in a morning tweet as the Senate opened what was billed as an unusual and open-ended debate on a host of immigration issues. Democrats had pushed for the debate, hopeful they might be able to craft a piece of legislation in real time on the Senate floor – or at least force Republicans on the record on some difficult issues.

But the experiment in legislating didn’t go very far.

Senate Majority Leader Mitch McConnell, R-Ky., began the process by throwing his weight behind legislation based on the president’s priorities.

To kick off the debate, McConnell proposed allowing Republicans to bring up an amendment targeting cities that don’t fully cooperate with federal immigration authorities, so-called “sanctuary cities.” Then, Democrats would bring up legislation of their choosing. Amendments gaining 60 votes would become part of the broader immigration bill.

The Senate’s top Democrat, Chuck Schumer of New York, quickly objected.

“To begin the debate as the Republican leader suggests would be getting off on the wrong foot,” Schumer said. “Very partisan.”

Schumer wants McConnell to bring up legislation that incorporates Trump’s priorities and a second, much narrower bill from Sens. John McCain, R-Ariz., and Chris Coons, D-Del.

His reasoning: The legislation should address the population of young immigrants that lawmakers from both parties say they want to help, rather than deal with side issues such as punishing sanctuary cities.

McConnell replied: “I’m not trying to dictate to them what they offer. They shouldn’t be trying to dictate to us what we offer. We ought to just get started.”

The disagreement pushed any immigration-related votes into Wednesday. That gives a group of moderate lawmakers more time to come up with a package that could generate 60 votes in the Senate.

“Until we reach an end there, I still hope that’s the vehicle,” said Sen. Jeff Flake, R-Ariz., one of the group’s key participants.

Exiting the Senate floor Tuesday evening, Sen. Dick Durbin, D-Ill., said “things change by the hour” on immigration, but he felt better as the day went on about the prospects of getting a bill passed. He said lawmakers are meeting privately in search of a compromise.

Trump, in an early-morning tweet, said Congress must act now to provide legal protections to young “Dreamer” immigrants.

“Wouldn’t it be great if we could finally, after so many years, solve the DACA puzzle,” he wrote, adding: “This will be our last chance, there will never be another opportunity! March 5th.”

Trump was referring to a deadline he announced last year to end a program protecting young immigrants from deportation, formally known as Deferred Action for Childhood Arrivals, or DACA. But a recent court ruling has rendered that deadline all but meaningless.

In an exchange later Tuesday with Sen. Sherrod Brown, D-Ohio, Trump again tried to accuse Democrats of not wanting to fix DACA, but then told the senator he was joking.

“Everybody’s in there working hard on it right now. I think we have a chance to do DACA very bipartisan. I think that can happen,” he said during a meeting on trade issues with lawmakers at the White House. “And I hope we’re going to be able to do that, senator.”