In a few hours (we're told somewhere around 5:45 to 6:15), the House is expected to vote on Speaker John Boehner's plan to raise the debt ceiling. Updated with a Balanced Budget Amendment component, his bill is all but assured of passage.
At that point, Senate Majority Leader Harry Reid, D-Nev., promises that he will immediately vote to table the bill, and introduce his own measure. Unless all 100 Senators agree to allow him to hold a vote on it immediately, he'll have to vote on cloture, which will set up a vote for 1 am Sunday morning.
Reid's bill likely doesn't have the 60 votes it needs to invoke cloture in its current form. This means that at some point, Boehner, Reid and Senate Minority Leader Mitch McConnell, R-Ky., will have to hash together a compromise.
Whatever compromise they work out will have to come back to the House for approval, where it will likely lose a significant chunk of Republicans, but presumably (if it's a pre-negotiated deal) would win over enough House Democrats to compensate.
Then it will head back to the Senate for approval and signature by President Obama. Given the tight timeframe, it's theoretically possible that a single Senator could blow up the whole deal by refusing to grant unanimous consent on Monday night, thus forcing Reid to wait past the Aug. 2 deadline to hold a cloture vote. However, when the clock was ticking on the deal to avert a government shutdown, nobody stood in the way of Reid holding a quick vote, so that would have to be the case here as well.