(This post was last updated at 9:55 p.m. ET.)
With just hours before the Department of Homeland Security would have run out of funding, the GOP-controlled House voted to approve a week-long funding extension that both sides hope will provide time needed to find a full solution through the end of the fiscal year.
The House immediately adjourned following the 357-60 vote.
The passage capped a day of scrambling that saw a longer three-week stopgap shot down in the House, 203-224, NPR's Juana Summers reports. More than 50 Republican upset with the deletion of a provision stripping funds from President Obama's immigration moves joined the chamber's Democrats, who at that time were still pushing for full funding through Sept. 30.
This battle has been brewing in Congress for months, since President Obama issued a series of executive actions giving legal status to millions of undocumented immigrants.
Democrats have successfully stopped bills that seek to overturn his actions, so to thwart the them, some Republicans have suggested defunding DHS, the home of Immigration and Customs Enforcement.
But Republicans in the House and Senate have failed to agree on a unified strategy. To avoid a partial shutdown of DHS, the Senate passed a so-called "clean bill" that would fund DHS until Sept. 30; the House leadership went forward with a more limited bill.
Ultimately, even after holding the vote open more than 30 minutes past the originally scheduled 15 minutes to try to flip votes, House Republicans could not cobble together the 217 votes they needed to pass the measure.
Update at 8:27 p.m. ET. Senate Passes One-Week Extension:
Giving the House another option, the Senate has passed a bill that would extend DHS funding for one week.
The Senate has now adjourned until Monday.
Now, the question becomes, what will the House do? At this point they have two choices: Allow funding to lapse, or vote on one of the Senate's two proposals.
At this point, House Republicans are still meeting behind closed doors.
Update at 5:38 p.m. ET. What Does this Mean?
Here's how NPR's Ron Elving sees the situation: "At this point," he says, "it's more a matter of persuading."
Ron says that this is another big test for the leadership of Speaker John Boehner, who will send out his whips to talk to the 51 Republicans who voted against the measure to try to convince them to reconsider.
There is a possibility, Ron said, that Boehner could cobble together enough to Democratic votes to make up for those in his caucus who voted against the measure, but that, too, has implications.
Ron says, at this point, it would difficult to bring another measure to the floor, so the realistic options are: Vote again on the measure that keeps DHS funded until March 19. Or, with the help of Democrats, pass the Senate's version of the bill.
The latter, Ron says, would be a "total victory for the Democrats and the president."
Update at 11:22 a.m. ET: Senate Approves Full Funding
The Senate has voted to fund Homeland Security through Sept. 30, providing the agency with full funding. The final tally was 68-31.
The Senate is expected to take up the House's stopgap measure later Friday, if it passes. That legislation has been moving forward in the House.
Our original post continues:
Just a day before the DHS was set to run out of money (at midnight tonight), Republicans in the Senate had come to terms with the need for a "clean" bill to fully fund the Department of Homeland Security, one that doesn't require changes to the executive actions President Obama has taken on immigration.
As NPR's Ailsa Chang reported, they've been hoping the House would follow suit.
Ailsa quotes Sen. Mark Kirk, R-Ill., who says the burden of the majority is the burden of governing: "As a governing party, we've got to fund DHS and say to the House, 'Here's a straw, so you can suck it up.' "
But on Thursday night, Republican leaders in the House came up with a different idea: to fund DHS for just three weeks to give the two chambers of Congress time to work out a compromise measure.
As The Associated Press reports, some Republicans in the House have said that shutting down DHS would be an acceptable cost of thwarting the executive actions on immigration.
From the AP:
" 'Shutting down' the agency known as DHS 'is a set of words that don't really have the meaning that people attribute to it,' said Republican Rep. Mo Brooks of Alabama. 'There was hardly any effect whatsoever on the Department of Homeland Security from the last shutdown, and I would anticipate a similar effect this time.'
"Brooks was referring to the 2013 partial federal government shutdown that Americans blamed mostly on Republicans, and which many GOP leaders have vowed not to repeat."
House Republicans have noted that many DHS workers, such as transportation security officers, were declared "essential" and went to work as normal during that shutdown. But as Ailsa reported earlier this week, those security officers were left without paychecks until after the shutdown was resolved.
Even if Congress adopts the three-week stopgap measure, the leaders of the two chambers will have to figure out how to resolve their different views — and their different styles.
"You know, the House by nature and by design is a hell of a lot more rambunctious place than the Senate," House Speaker John Boehner said Thursday.