The Supreme Court in June 2017. (Matt McClain/The Washington Post)

The justices of the Supreme Court revisited their youthful decisions and the parties they once attended in a case Wednesday about policing that began with trespassing arrests at a raucous D.C. house party hosted by a woman named Peaches.

Some of the court's more liberal justices seemed uncomfortable with the idea that their younger selves could have been arrested merely for accepting an invitation without knowing the host or whether the host had permission to throw the party.

"Twenty-one people arrested en masse for trespassing for going to a party. Does that feel right?" Justice Sonia Sotomayor asked the lawyer defending the D.C. government and two police officers.

Justice Elena Kagan reminisced about the parties she was invited to "long, long ago" without knowing the host and, added coyly, where "marijuana was maybe present at those parties." She asked the Justice Department lawyer whether it was reasonable to assume that a partygoer would know that a host did not have permission to organize a gathering.

"It seems a little hard that they are subject to arrest," Kagan said.

Even as some justices appeared sympathetic to the partygoers, they said police have to be able to make judgment calls about suspects and circumstances they investigate. Government officials, including police officers, generally are shielded from lawsuits when they carry out their duties in good faith.

The court on Wednesday was considering whether the D.C. officers were justified in making the arrests at the party on Anacostia Avenue in March 2008. And, even if the officers made a bad call, and did not meet the "probable cause" standard, whether they should still be protected from lawsuits.

Sixteen of the partygoers sued the officers and city after the criminal charges were dropped, and a federal jury awarded $680,000 in damages that eventually reached nearly $1 million with legal costs added. The city went to the U.S. Court of Appeals for the District of Columbia Circuit, and a divided three-judge panel sided with the partygoers, finding that the officers were not immune from legal action for the unlawful arrests.

The two officers — Andre Parker and Anthony Campanale — and D.C. Police Chief Peter Newsham were at the Supreme Court in uniform listening to the oral arguments.

D.C. Solicitor General Todd S. Kim urged the justices to consider the perspective of the officers called to the scene to investigate complaints about a loud party at what a neighbor said was a vacant home on a typically quiet block in Northeast.

"Suspects on the scene offer any number of different types of innocent explanations for conduct. These will often be false," Kim said, and "police officers need the leeway" to discredit those excuses.

Chief Justice John G. Roberts Jr. and Justice Samuel A. Alito Jr. pressed the lawyer for the partygoers about what else the police could have done. Wasn't it reasonable, Roberts asked, to investigate community complaints about a loud party in a vacant home, and hadn't the officers thoroughly interviewed the guests before making the arrests, he wanted to know.

Attorney Nathaniel P. Garrett, who represented the partygoers, said the police failed to consider that the partygoers believed they were welcome at the home.

When police arrived at the brick duplex after 1 a.m., the party was underway in the sparsely furnished home, with women performing lap dances in skimpy tops and garter belts stuffed with cash. Partygoers told police that "Peaches" had invited at least some of them, with guests and dancers giving varying reasons for the party. Some said it was a birthday party; others said it was a bachelor party.

But Peaches was not there. When officers at the scene phoned the homeowner, he told them he had not approved a party.

"She lied to the officers. She said that she had authority to throw a party there, and she didn't. All of those things, I think, would fit into a reasonable officer's understanding of the facts and suggest that they may be hearing a story that is not true," said Assistant Solicitor General Robert A. Parker, who also argued on behalf of the city and the officers.

The conflicting stories from the partygoers and Peaches captured the attention of the court, with Alito asking the partygoers' attorney, "Just out of curiosity, who is the bachelor at this bachelor party?"

And later, Justice Anthony M. Kennedy added somewhat incredulously: "So Peaches is the host at a bachelor party. Is that it?" he asked, prompting laughter from the courtroom.

As it turns out, Peaches routinely hosted such parties as a side business to her job as a bartender, according to friends who knew her as Veronica Little and said she died of an illness last year.