This is what compromise looks like in the era of President Trump vs. House Speaker Nancy Pelosi (D-Calif.): Success is an orphan, while failure continues to have many mothers and fathers.

Usually, a massive spending bill on Capitol Hill with outlays of more than $300 billion for purposes including the State Department’s diplomats abroad, the Coast Guard’s drug-fighting agents and TSA agents at airports would have enough to make almost everyone happy.

But the bill that seems likely to pass Congress by Friday — ending, for now, a several-month standoff over border security — appears to be a rare orphan heading toward Trump’s desk.

No one wants to take credit for its passage.

One of its authors, Rep. Pete Aguilar (D-Calif.), summed up his sales pitch to Democrats as the least bad option they are going to get — that if this bill does not pass, either the government shuts down or Congress passes a bill that leaves agencies working off last year’s budget.

“What we’re asking them to do is to weigh the competing interests of what’s in this bill versus also what would happen if this bill didn’t move forward,” Aguilar told reporters outside a Democratic meeting Wednesday.

He was not quite asking them “to hold their nose” and support the bill, but he acknowledged that it was far from perfect.

As she entered the same meeting, House Speaker Nancy Pelosi (D-Calif.) gave a similar pitch: that the final kinks must be ironed out to pass the bill because the alternative was intolerable, a replay of the shutdown in December and January that shattered previous records for the length of ineptitude.

“We have to. We have to. I think we’re in a pretty good place,” Pelosi said.

Don’t look to Republicans, either, to claim ownership of this, even though President Trump has given signs that he thinks it is a decent compromise.

Ask House Minority Leader Kevin McCarthy (R-Calif.) how many GOP votes the legislation will get, and his likely response will be to laugh, as he did Tuesday afternoon.

The legislation, if it passes and Trump signs it, will complete the 2019 fiscal year process that was supposed to be concluded 4½ months ago.

It is the final item left over from the previous era of complete Republican control of government, a strange budget process that began with Paul D. Ryan (R-Wis.) as the sitting House speaker and will end with Ryan’s 2012 running mate, former GOP presidential nominee Mitt Romney (R-Utah), as one of the most junior members of the Senate.

The reality is that the legislation became consumed by a sliver of its overall funding — Trump’s demand for more than $5 billion for additional wall along the U.S.-Mexico border, with Democrats willing to fund only a fraction of that and to limit it to fencing rather than wall.

So rather than go through another shutdown, each side agreed that this was the best alternative. It is a victory for Pelosi and Democrats, if the measure of victory is whether they stood firm against the wall.

“We accomplished what we set out to accomplish,” said Rep. Bill Pascrell Jr. (D-N.J.). “We’re not going to get a wall from sea to shining sea.”

But the more they looked at the legislation, some Democrats realized that Trump could claim victories in the overall funding level for border security.

Rep. Pramila Jayapal (D-Wash.), a leader of the congressional Progressive Caucus, was outraged by Democrats’ inability to keep the Trump administration from detaining more undocumented immigrants than current law dictates.

After the Democratic huddle, she said she was “leaning no.”

Would she use her clout to try to bring the legislation down? No.

“We’re not trying to kill this bill,” Jayapal said, making clear that her caucus was “not whipping” against the legislation.

Jayapal is one of the more-liberal firebrands with the potential to play a similar role as Rep. Mark Meadows (R-N.C.) did during the previous six years — a thorn in the side of party leadership. Time and again, Meadows, chairman of the House Freedom Caucus, worked to undermine Ryan and John A. Boehner (R-Ohio) during their tenures as speaker.

In Ryan’s last days in office, Meadows pushed Trump to reject the outgoing speaker’s advice and start what became a 35-day partial shutdown of the federal government.

Not anymore. Meadows thinks the pending legislation is a lousy piece of work that does not build a wall and spends too much money. But he’s taking the same approach as Jayapal, voting no and otherwise allowing it to pass without much outcry because Trump has said he does not want to shut down the government again.

“He wants to keep the government open, I want to keep the government open,” Meadows told reporters Tuesday, suggesting that he would prefer sticking with last year’s funding plan. “But if this is the vehicle that he uses to keep the government open, so be it.”

Most of this tepid support and tepid opposition is driven by the mercurial president, whose every whim can seem to increase or decrease the likelihood of his supporting a piece of legislation that divides his primary backers.

Pelosi and most Democrats agree that the legislation is about the best they can do, considering that the process began when Republicans ran the entire town. But if she were to run around declaring victory and metaphorically spiking the football, Pelosi might prompt Trump to turn against the legislation and end up vetoing the package.

Also, many Democrats have grown to detest Trump so much that, if it is something that he is signing into law, they have difficulty expressing real enthusiasm for it.

And Republicans got burned in this very scenario two months ago, when Meadows and conservative activists persuaded the president to oppose the carefully laid-out plan that Ryan and Senate Majority Leader Mitch McConnell (R-Ky.) had crafted to extend government funding through the holidays and into early February.

After McConnell’s Senate unanimously supported that plan, Trump cut their legs out from under them, starting the shutdown.

So now, as a very important piece of legislation is set to become law, no one wants to take credit for it.

“When you strike a deal, you get some things that you want and you get some things that you don’t like,” said Rep. Gregory W. Meeks (D-N.Y.).

Read more from Paul Kane’s archive, follow him on Twitter or subscribe to his updates on Facebook.