The U.S. Senate failed Wednesday to advance a bipartisan proposal to tighten migration controls along the U.S.-Mexico border that would also have provided billions of dollars of military aid to Ukraine and Israel.

Republican lawmakers have long demanded tougher regulations to halt the daily influx of thousands of migrants fleeing crime and poverty in their homelands and seeking better lives in the United States. But in the end, enough Senate Republicans killed the measure by opposing a motion to open debate on it.

The immigration issue, long unresolved by Congress and succeeding Republican and Democratic presidencies, quickly became embroiled this year in the politics of the 2024 presidential election campaign.

The leading Republican contender, former President Donald Trump, pushed his Republican colleagues in Congress to oppose the legislation unless they got everything they asked for on immigration. Democrats charge that he wants the chaos at the border to continue so he can use it as a campaign issue against President Joe Biden.

Biden said at a Tuesday news conference he would hold Trump accountable for the arrival of more migrants. Under existing law, many who enter illegally and claim asylum are able to remain in the United States for months or years before backlogged immigration courts can consider their cases.

FILE - Sen. Chris Murphy, the Democrats' chief negotiator in border security talks, speaks to reporters in Washington, Dec. 19, 2023. The Senate on Feb. 7, 2024, failed to advance a bill to tighten migration controls at the U.S.-Mexico border.

FILE – Sen. Chris Murphy, the Democrats’ chief negotiator in border security talks, speaks to reporters in Washington, Dec. 19, 2023. The Senate on Feb. 7, 2024, failed to advance a bill to tighten migration controls at the U.S.-Mexico border.

With the defeat of the immigration bill, the Senate now is set to consider legislation that would provide the aid to Ukraine and Israel, minus any border immigration provisions.

Biden on Tuesday urged Congress to show “some spine” and pass the broader bill, which was developed during months of negotiations by a small group of Democratic and Republican senators.

Even had the Senate passed it, Speaker Mike Johnson, leader of the narrow Republican majority in the House of Representatives, declared it “dead on arrival” in the lower chamber. He said the migration restrictions were not tough enough.

In his Tuesday speech, Biden said, “All indications are this bill won’t even move forward to the Senate floor. Why? The simple reason: Donald Trump.”

He added, “Because Donald Trump thinks it’s bad for him politically.”

Biden said if the legislation was defeated, “every day, Americans will know why the border is not secure — Donald Trump.”

Trump had urged Republicans to oppose the proposed migration controls as weak and said that he would impose tougher rules to keep migrants out of the U.S. if he reclaims the presidency in the November election, where he is likely to again face Biden.

The U.S. has been Ukraine’s biggest benefactor, and Biden said it was important to send the new $60 billion in aid to Kyiv to help it fend off Russia’s nearly two-year-old invasion.

“We can’t walk away now,” he said, adding that to deny the additional aid would be a gift to Russian President Vladimir Putin.

“History is watching,” Biden said. “If we don’t support Ukraine, history will never forget.”