Washington (CNN) -- Two opposing Senate leaders didn't let a tense history get in the way as they steered negotiations to end the partial government shutdown and extend the debt ceiling.
When talks between House Republicans and the White House came to a standstill, the negotiating spotlight moved over the weekend to Senate Majority Leader Harry Reid and Minority Leader Mitch McConnell.
And with Tuesday's collapse of a last ditch effort by House Republicans, the ball returned to Reid and McConnell's court.
And that raised questions about their strained relationship and whether it would have endangered a compromise.
After a deal was struck on Wednesday, both men took to the floor of the Senate.
"This time was really hard. But after weeks of facing off across a partisan divide that often seemed too wide to cross, our country came to the brink of a disaster. But in the end, political adversaries set aside their differences and disagreements to prevent that disaster," said Reid.
"After yesterday's events the majority leader and I began a series of conversations about a way to get the government reopened and to prevent default. I'm confident we'll be able to do both those things later today," said McConnell, moments later.
Monday both leaders used some of their time on the floor to praise the other.
"I deeply appreciate my friend, the minority leader, for his diligent efforts to come to an agreement," said Reid.
"Let me just echo the remarks of my good friend, the majority leader," added McConnell.
The compliments from both men were at odds with the bitter comments the two have flung at each other in the past.
Hard feelings boiled over this summer when they battled over a Democratic push to amend filibuster rules. McConnell called Reid "the worst leader in the Senate, ever."
"Both are creatures of the Senate. But from Reid's perspective, Sen. McConnell has run nothing less than a filibuster on steroids over the past couple of years," says Democratic strategist Jim Manley, Reid's former senior communications adviser.
"There's no denying that relationship has taken a pretty significant turn for the worse in the last year or so. Anyone, who's seen the sparring on the Senate floor each morning understands that."
Earlier Monday, Reid downplayed talk of a frayed relationship.
"That's greatly exaggerated. Sen. McConnell and I have worked together for more than 30 years, very closely since we've been whips. So no problem," Reid told reporters.
McConnell's former chief of staff, Josh Holmes, agrees, saying he doesn't buy into such stories.
"There's a lot of people trying to make a lot out of the relationship," says Holmes, who's now a Republican consultant helping McConnell's 2014 re-election campaign and the National Republican Senatorial Committee.
Both in their early 70s, the two lawmakers have combined have served nearly 60 years in the chamber and have similar backgrounds.
McConnell of Kentucky was first elected to the Senate in 1984. Reid, the Nevada Democrat, entered the chamber two years later. Both sat on the Appropriations Committee and both were whips, the No. 2 party position in the Senate responsible for rounding up votes.
Regardless of their common history and similar paths to power, Reid and McConnell don't appear to be that close personally.
"To say they're friends outside of the office is a pretty significant stretch," adds Manley, a senior director at QGA Public Affairs. "In recent years, when they've been battling each other on the Senate floor, the only thing they find in common in the Washington Nationals."
Campaign politics may be a contributing factor.
McConnell is up for re-election next year and not only faces a Democratic challenger at home in Secretary of State Alison Lundergan Grimes, but also a primary challenge from businessman Matt Bevin, who enjoys the support of some tea party and other grassroots conservative activists.
Reid helped recruit Grimes and was supposed to appear at a Las Vegas fundraiser for her but missed it because of the ongoing shutdown and debt ceiling impasse.
"Is it helpful that you have a majority leader throwing a fundraiser for your opponent? Probably not," adds Holmes. "But McConnell's a grown up and he's certainly not going to use that as a reason to not get a result."
When Reid faced a bruising re-election four years ago, McConnell never campaigned with the GOP challenger, Sharron Angle.
But the National Republican Senatorial Committee, which is the campaign arm of the Senate GOP, did go up with some tough commercials attacking Reid.
The Senate tradition that the chamber's top two leaders would refrain from actively campaigning against each other back home ended in 2004, when then-Senate Republican leader Bill Frist got involved in the successful drive to defeat then-Senate Democratic Leader Tom Daschle of South Dakota.
Despite all this bad blood over the past few years, Manley points out that both "Reid and McConnell "are smart enough to know when to compromise."