The latest effort to hold former president Donald Trump and his allies accountable for months of baseless claims about the 2020 election played out Monday in a Michigan courtroom, where a federal judge asked detailed and skeptical questions of several lawyers she is considering imposing sanctions against for filing a suit seeking to overturn the results.

U.S. District Court Judge Linda V. Parker said she would rule on a request to discipline the lawyers in coming weeks. But over and over again during the more than five-hour hearing, she pointedly pressed the lawyers involved — including Trump allies Sidney Powell and L. Lin Wood — to explain what steps they had taken to ensure their court filings in the case filed last year had been accurate. She appeared astonished by many of their answers.

While their suit aimed to create a broad impression that the vote in Michigan — and specifically Detroit’s Wayne County — had been troubled, the affidavits filed to support those claims included obvious errors, speculation and basic misunderstandings of how elections are generally conducted in the state, Parker said.

“There’s a duty that counsel has that when you’re submitting a sworn statement . . . that you have reviewed it, that you had done some minimal due diligence,” she said.

As the hearing concluded, a defiant Powell told the judge that she took “full responsibility” for the case’s pleadings and said she would file them again. She and the other lawyers “had a legal obligation to the country” to raise issues with the election, Powell said.

If Parker decides to discipline the lawyers, she could require them to pay the fees of their opponents in the case, the city of Detroit and Michigan state officials. But she could also go further — assessing additional monetary penalties or recommending grievance proceedings be opened that could result in banning the attorneys from practicing in Michigan or disbarring them altogether.

The Michigan hearing is part of a broad move underway nationally to hold responsible Trump and his backers who spread falsehoods about the election, the so-called “big lie” that led to the violent attack on the U.S. Capitol on Jan. 6.

The push for accountability has been advancing in the nation’s courts in recent months, even as Republicans have embraced Trump’s baseless claims and blocked an independent commission to scrutinize the failures that contributed to the Jan. 6 riot.

The effort, playing out in several states, includes attempts to punish attorneys who pursued dozens of failed efforts to use the courts to overturn the election, the filing of defamation lawsuits against key figures who falsely claimed voting machine manufacturers tipped the election, and the launch of criminal investigations examining whether Trump and his allies broke the law by trying to interfere with the official administration of the election.

One of the first substantial repercussions came last month, when a committee of judges in New York state suspended the law license of former New York mayor Rudolph W. Giuliani, who served as Trump’s personal attorney. The committee found that Giuliani had “communicated demonstrably false and misleading statements to courts, lawmakers and the public at large” in violation of his ethical obligations as an attorney.

Representatives for Giuliani have called the action “unprecedented” and expressed confidence that his law license will be restored after a hearing to determine whether to revoke his license permanently.

In Wisconsin, Gov. Tony Evers (D) has asked a federal judge to order Trump and three of his attorneys to pay the state’s attorneys’ fees in a case the former president filed in December unsuccessfully challenging President Biden’s win there. Trump and his lawyers told a judge in a court filing Monday that the request for attorney’s fees was “untimely and unwarranted.”

Authorities in several states have also opened criminal probes related to the post-election period, including in Fulton County, Ga., where District Attorney Fani Willis launched a criminal investigation in February, in the wake of Trump’s calls to state officials to try to persuade them reverse Biden’s victory in the state.

Jeff DiSantis, a spokesman for Willis, said Friday that the investigation is ongoing.

Earlier this year, Willis said her office was investigating whether “attempts to influence” the administration of the 2020 election in the state violated state law. She said she would examine contacts made with the offices of Georgia Secretary of State Brad Raffensperger, Gov. Brian Kemp and Attorney General Chris Carr, as well as with the General Assembly, which held hearings where Giuliani and others made unfounded allegations of fraud. Under Georgia law, it is illegal to lie under oath to the General Assembly.

An individual with knowledge of the investigation who spoke on the condition of anonymity because it is an active case said that the “voluntary phase” of the investigation is winding down and that subpoenas are likely to be issued soon to those who did not agree to be interviewed or turn over documents.

A separate investigation is now under underway in Michigan. A spokeswoman for state Attorney General Dana Nessel (D) last week confirmed her office has opened a case exploring the activities of individuals who have been raising money by circulating false claims that the election results in Antrim County were manipulated, an allegation that has been widely touted by Trump allies. Nessel’s spokeswoman said the Michigan State Police are involved in the case.

Nessel’s announcement came after a state Senate committee led by Republican Sen. Ed McBroom concluded last month that had been “no evidence of widespread or systematic fraud” in Michigan and recommended Nessel “consider investigating those who have been utilizing misleading and false information about Antrim County to raise money or publicity for their own ends.”

In Arizona, Secretary of State Katie Hobbs (D) wrote a letter to Attorney General Mark Brnovich (R) last week, asking that his office open an investigation into whether Trump and allies — including Giuliani and Arizona GOP Chairwoman Kelli Ward — might have violated a state law that makes it illegal to knowingly interfere with an election officer.

Her letter cited text messages and voice mails recently obtained via public information laws by the Arizona Republic that detailed a pressure campaign aimed at persuading members of the Maricopa County Board of Supervisors not to certify Biden’s victory in the county, which is home to Phoenix.

In one voice mail, Giuliani told one Republican supervisor: “I’d like to see if there’s a way that we can resolve this so that it comes out well for everyone. We’re all Republicans, I think we have the same goal.”

Another message showed that Ward texted the board’s chairman four days after the election — a time when ballots were still being tallied that ultimately confirmed Biden’s narrow in the county. “We need you to stop the counting,” she wrote.

A spokeswoman for Brnovich said he had received the letter and would review it, declining to comment further.

Meanwhile, a series of $1.3 billion defamation suits filed by Dominion Voting Systems against Giuliani, Powell and MyPillow chief executive Mike Lindell are moving through the civil courts. The company argues that the three Trump allies lied repeatedly about the company, creating a “viral disinformation campaign” that convinced the public that Dominion’s voting machines were used to flip Trump votes to Biden and swing the election.

A judge in Washington held a four-hour hearing in the matter last month and could decide whether to grant a motion to dismiss the suit at any time.

The focus of the Michigan hearing Monday was a lawsuit that involved nine lawyers, including Powell and Wood, that was brought on behalf of six local Republicans in late November after Biden’s victory in Michigan had been certified.

One of series of lawsuits known as the “Kraken” cases — after Powell promised her lawsuits would amount to releasing the mythical creature in Trump’s defense — the Michigan suit filed by the Trump allies argued the election had been marred by widespread fraud. The suit had asked Parker to order that Biden’s win be decertified and require that Trump be declared the winner of Michigan’s 16 electoral votes.

Parker, who was appointed to the bench by President Barack Obama, formerly served as the director of Michigan’s Department of Civil Rights.

In a stinging opinion in December, she rejected the request, writing that the relief the plaintiffs had sought was “stunning in its scope and breathtaking in its reach.”

“If granted, the relief would disenfranchise the votes of the more than 5.5 million Michigan citizens who, with dignity, hope, and a promise of a voice, participated in the 2020 General Election,” she continued, adding that the plaintiffs had advanced “nothing but speculation and conjecture that votes for President Trump were destroyed, discarded or switched to votes for Vice President Biden.”

Lawyers for the city of Detroit, as well as Nessel, acting on behalf of the state’s governor and secretary of state, later moved for the lawyers to be disciplined, arguing the case the lawsuit was frivolous and relied on false evidence. Legal rules and federal law require lawyers be truthful in court and avoid filing cases “unreasonably and vexatiously.”

David Fink, a lawyer for the city of Detroit, told the judge Monday that the suit had helped undermined faith in the election and helped lead directly to the Jan. 6 attack. “We can’t undo what happened, but this court can do something to let the world know that attorneys in this country are not free to use our courts to tell lies,” he said.

The lawyers rejected that claim and said their suit was a good-faith effort to use the court system to address concerns with the election.

“Civil complaints do not foment revolution,” said Donald Campbell, a lawyer representing the group. Instead, he argued that denying access to the courts to people who believe an election has been compromised“is what is dangerous.”

During the hearing, Powell took primary credit for writing the complaint, along with New York lawyer Howard Kleinhendler. (Wood argued he should not face sanctions because, according to Wood, he played no role despite the inclusion of his name on the complaint.)

Parker quizzed the lawyers about whether there is any legal basis to ask a judge to decertify an election and name a new winner. And she spent hours asking the attorneys to explain how closely they had reviewed and vetted information submitted in hundreds of pages of sworn declarations that they had told the court constituted evidence of purported fraud and irregularities.

The judge noted that one observer stated in an affidavit that she believed she saw election workers switching votes from Trump to Biden. Parker asked whether any of the lawyers had spoken to the witness and inquired what exactly she saw that led her to believe that votes had been switched. She was greeted with silence.

“Anyone?” she asked again.

When no one answered a second time, she said: “Let the record reflect that no one made that inquiry, which was central to [the] allegation.”

She focused on another statement from a witness who swore he saw individuals placing clear plastic bags into a mail truck — and said he believed the bags “could be ballots” headed for Detroit’s counting facility.

The judge called that allegation “really fantastical” and “speculative.”

“I don’t think I’ve really ever seen an affidavit that has made so many leaps,” she said. “My question to counsel here is, how could any of you as officers of the court present this type of an affidavit?”

Julia Haller, one of the lawyers who filed the original suit, responded that the statement accurately reflected what the man believed he had seen and that the affidavits should be viewed collectively as suggesting a “pattern of fraud.”

She and the other lawyers repeatedly asked to be allowed an opportunity to bring their witnesses into court and have them be questioned about their evidence and qualifications before being disciplined over their sworn statements.

One declaration came from a witness referred to by the lawyers in court documents only as “Spider.” In his sworn declaration, he claimed to be a former military intelligence expert who had discovered server traffic revealing that Iran and China had tampered with the election. But The Washington Post revealed in December that “Spider” was actually a 43-year-old Texas-based information technology consultant named Joshua Merritt who never worked in military intelligence.

Records show he enrolled in a training program with a military intelligence battalion but never completed the entry-level course, an Army spokeswoman told The Post. Records show that Merritt spent most of his decade in the U.S. Army as a wheeled vehicle mechanic.

In court Monday, Kleinhendler told Parker that Merritt had done training with the intelligence unit and was prepared to testify about his qualifications — but only in a sealed hearing because of the confidentiality of his work.

In another instance, a cybersecurity analyst based in Texas stated in a sworn declaration that more than 139 percent of registered voters in the city of Detroit had cast ballots — a dramatic irregularity that, if true, would have signaled obvious problems or fraud in the predominantly Democratic city.

However, city records showed that just under 51 percent of registered voters cast ballots.

While that error was corrected in later filings in the case, Fink noted to the judge that among those who would go on to echo the claim was Trump, who mentioned the false statistic in a Jan. 2 phone call to the secretary of state of Georgia as he sought to overturn Biden’s win in that state.

“The suggestion that this is some kind of harmless error because it was ultimately corrected flies in the face of the reality of what actually happened,” Fink said. “These lies were put out into the world. When they were put out into the world, they were believed.”

Amy Gardner and Emma Brown contributed to this report.