THE BAND OF RIGHT-WING provocateurs who staged a “straight pride” parade in Boston 10 days ago were hoping to stir the pot. But they likely never imagined that the tempest they’d cause would be a judicial showdown among local officials that exposes tensions set off by last year’s election of a reform-minded district attorney.

Things got unruly in the streets as the straight pride marchers were met by hundreds of counter-demonstrators, but there wasn’t exactly order in the court either when the cases of many of the three dozen counter-protesters who were arrested came before Boston Municipal Court Judge Richard Sinnott.

Sinnott repeatedly, over the course of two days, rejected efforts by prosecutors to dismiss cases against those arrested for non-violent offenses of disorderly conduct or resisting arrest. (The DA’s office said it was pursuing cases against those charged with violent crimes, including assaulting police officers.) The problem: It’s not clear Sinnott is within his rights to do so, as charging decisions are generally the province of prosecutors.

Susan Church, a well-known local defense lawyer, says Sinnott absolutely was out of bounds in refusing prosecutors’ efforts to drop charges against a young woman she was representing on charges of disorderly conduct and resisting arrest. Church was so emphatic in that belief that she got into a testy exchange with Sinnott that ended with the Cambridge lawyer hauled out of court in handcuffs for contempt when Sinnott ordered her to stop making her argument but she persisted.

“He has no leg to stand on,” Church said about Sinnott’s ruling on this week’s Codcast. Describing her experience of being handcuffed and held for several hours in the courthouse lock-up area as “surreal,” Church offered her account of what transpired in the courtroom.

She said Sinnott would not allow her to complete her argument, in which she was citing cases, including a 1991 Supreme Judicial Court ruling, that made clear that prosecutors, as part of the executive branch of government, retain the complete right to press forward or drop charges in a case, with no role for the judiciary in that aspect of the proceedings.

“As soon as I start reading those cases, he starts interrupting me,” said Church.

A transcript of the proceedings shows Sinnott raising questions with her about the state’s victims’ rights statute, something Church insists isn’t germane to the issue at hand. He also warns her not to talk over him, and when she asks to finish reading a case citation, he says no. When she continues speaking, Sinnott orders her removed.

Church says things happened while she was detained that she can’t talk about because they may be the subject of further proceedings. She also charged that “even more will come out now” about Sinnott’s mistreatment of defendants in his courtroom.

Well-known Boston area lawyer Wendy Murphy wrote in yesterday’s Herald that there’s no equal footing between attorneys and judges in a courtroom dispute. “It’s first-year law school stuff that in these verbal duels with the court, the lawyer has to cede to the judge,” Murphy wrote.

It all made for a wild courtroom scene, but the tense standoff and hauling off of Church in handcuffs is just background to the real drama playing out. The showdown is over efforts by Suffolk County DA Rachael Rollins to reset the office’s approach. Rollins has vowed to make the default position of her office not to prosecute a list of 15 lower-level offenses. It’s part of her pledge to loosen the grip she says ensnares too many people in the criminal justice system, saddling them with a record that makes it hard to land jobs and otherwise stay on a productive path.

Boston police union leaders, who have already tangled repeatedly with Rollins, applauded Sinnott’s rulings to keep the cases going. Union vice president Larry Calderone suggested to reporters, however, that Rollins is not doing anything that different from her predecessors when it comes to handling arrests from demonstrations. That would seem to make the cases odd ones for a test of Rollins’s reform agenda.

Although Murphy wrote in yesterday’s Herald that judges effectively are emperors in charge of their courtrooms, when it comes to the substance of what’s being argued, “It doesn’t mean the judge is right, and in my experience, the judges are often wrong.”

On the question of whether Sinnott can block prosecutors from dropping charges, Church says Sinnott absolutely is wrong. (She points out that in her client’s case, the DA’s office filed a “nolle prosequi,” the Latin term for a notice they are dropping charges. It’s one of two ways prosecutors look to dismiss a case, and it’s the one, Church says, where the proscription of any role for the judge is most unequivocal.)

Rollins was indignant at Sinnott’s moves, calling them “an unconstitutional abuse of his power.” She also pointed out that prosecutorial discretion is why Sinnott was never charged after being involved in a 1980 conflict in which he shot someone on City Hall Plaza.

Rollins has petitioned the Supreme Judicial Court to overturn Sinnott’s ruling in one of the cases, a move she hopes will serve as a precedent for the others.

In a sign of how upside down things have become from the longstanding status quo in Suffolk County, Church, an outspoken progressive defense lawyer, raved about the job Rollins is doing.

She also said she has confidence in what Justice Frank Gaziano, the single justice of the SJC assigned to consider the DA’s petition, will do because he’s a former prosecutor.

“He’s a former prosecutor, and I think he will fully and 100 percent understand the law,” she said. “I haven’t met a prosecutor yet who sides with the judge in this case.”