ONE VETERAN House lawmaker said on Monday that Ron Mariano’s ascension as speaker has been one of the smoothest, most unified, most calm transitions he has ever witnessed.

That’s because this speaker transition is following a script that has been honed and crafted for years. As House Speaker Robert DeLeo prepares to hand off the speakership to his majority leader, the two men have left very little to chance.

The transition, according to sources, began several years ago when Mariano and his allies began lining up support. It was done quietly, with rumors only occasionally surfacing. No one would say anything on the record about the vote-gathering, but in retrospect the most important thing about it was that DeLeo let it happen.

In the past, DeLeo dealt with potential threats to his leadership decisively. In January 2011, he demoted Charlie Murphy, his Ways and Means chair, and James Vallee, his majority leader, who reportedly were building their own power bases in the House. Both men left the House the next year.

 Brian Dempsey, the former chair of the Ways and Means Committee and the man who many considered the heir apparent to DeLeo, left the House in 2017 to take up lobbying. Rep. Russell Holmes of Boston took note of Dempsey’s departure and suggested the Black and Latino Caucus “should be strong and united in our selection of the next speaker of the House.” For that remark, he lost his vice chairmanship of the Housing Committee.

Yet DeLeo did nothing when Mariano began soliciting support, suggesting the speaker had given his blessing to his majority leader. To be sure, Mariano and his allies were not seeking to topple DeLeo. They were only gathering pledges of support, preparing for the day when DeLeo, the state’s longest-serving speaker, would decide it was time to move on.

That day arrived last Wednesday, when NBC10’s Alison King, citing a source, said DeLeo was planning to take a job at Northeastern University. DeLeo’s office released a strange statement saying the speaker “has had no such talks with, much less does he have any agreement with, Northeastern University.”

The very next day Mariano’s allies in the House told reporters the race to succeed DeLeo was effectively over.

“I would say there is no speaker’s race,” Rep. Claire Cronin of Easton, the chair of the Judiciary Committee, told the Boston Globe.I think when Speaker DeLeo decides to leave or whenever he does leave, Leader Mariano will be the next speaker of the House.”

Michael Moran, the second assistant majority leader, told CommonWealth the same. “When and if Bob DeLeo decides that he is going to leave, I am very, very, very confident that Ron Mariano is going to replace him,” he said.

On Friday, right on cue, DeLeo filed a notice with the clerk of the House disclosing that he was about to begin job negotiations with Northeastern. The notice said he had not had any discussions yet with Northeastern, but somehow, the notice implied, he knew now was a good time to begin them.

Holmes announced on Friday that he would run for speaker. A couple veteran lawmakers who are retiring this year, Reps. Jonathan Hecht of Watertown and Denise Provost of Somerville, decried the wired transition in an op-ed in CommonWealth. But everybody else on Beacon Hill kept their mouth shut. In truth, the decision about who would be the next speaker of the House was made long ago and now the House is just going through the motions.