HELENA, Mont. (AP) - Congressman-elect Greg Gianforte avoided jail time after pleading guilty Monday to an election-eve assault on a reporter that turned the race for Montana’s lone U.S. House seat into a full-fledged political spectacle.

The Republican tech entrepreneur instead will serve 40 hours of community service and attend 20 hours of anger management classes for throwing Guardian reporter Ben Jacobs to the ground at Gianforte’s campaign headquarters in Bozeman on May 24.

For all the national attention the audiotaped assault brought to the race in its waning hours, the judge, prosecutors and the new congressman’s attorneys maintained Monday he was treated like any other first-time misdemeanor offender.

There was one notable exception, however: Gallatin County Justice of the Peace Rick West said he would allow prosecutors and the defense several weeks to argue over his order that the rookie politician be fingerprinted, photographed and booked like other defendants.

West ordered Gianforte to pay $385 in fines and court costs in addition to his 180-day suspended jail sentence, meaning he will be under court supervision until late November and will be able to petition to have the conviction removed from his record.

Gianforte is expected to travel to Washington within the next few weeks to be sworn in by House Speaker Paul Ryan.

A coalition of press groups had called on a congressional committee to censure Gianforte for the attack, and Democrats have demanded he step aside. Some of Gianforte’s fellow Republicans, including Ryan, have criticized him over the assault but said he simply needed to apologize.

“This was not a proud moment, but I’m ready to move on,” Gianforte said outside the courtroom.

From the start, there was little question that Gianforte would avoid jail time in light of the extent of Jacobs‘ injuries and Gianforte’s clean record.

“Given a complete lack of a criminal history, given all that he’s done for the community and who he is, I think the assault was aberrant behavior that will not be repeated on his part,” county Attorney Marty Lambert said outside court.

Gianforte was questioned by sheriff’s deputies at his headquarters shortly after the attack, then didn’t appear in public again until his victory speech the next night, in which he apologized to voters and to Jacobs.

Audio posted by Jacobs shortly after the attack recorded sounds of a scuffle, followed by Gianforte yelling for the reporter to “get the hell out of here.” Jacobs tweeted that Gianforte had “body slammed” him and broke his glasses while he tried to question him.

During Monday’s hearing, the judge tried to extract details of the confrontation from Gianforte.

“I knowingly made physical contact with Mr. Ben Jacobs that was insulting or provoking in nature and although it was not my intent to hurt him, I understand Ben was injured in this contact,” Gianforte said.

“I grabbed for his wrist. A scuffle ensued, and he was injured,” he said. “In the scuffle we fell on the floor, and I understand his elbow was injured.”

A Fox News reporter who witnessed the attack said Gianforte, completely unprovoked, pushed Jacobs to the ground and punched him.

Despite the confrontation, Gianforte was elected by 6 percentage points over Democrat Rob Quist to serve the remainder of the term vacated by Ryan Zinke, who resigned to become Interior Department secretary.

The vast majority of ballots were cast by mail well beforehand.

Gianforte’s attorneys, including former U.S. Attorney Bill Mercer, noted that he had already paid more than $4,600 in restitution to Jacobs as part of the criminal case. The money included expenses for medical bills and transportation to attend Monday’s court hearing, among other costs, Guardian spokeswoman Meghan Pianta told The Associated Press.

Gianforte also agreed to give $50,000 to the Committee to Protect Journalists and wrote Jacobs a letter of apology in which he acknowledged assaulting the reporter for asking a “legitimate question about health care policy.”

Despite those repeated apologies, Gianforte has yet to fully address why his campaign’s initial account of the confrontation cast blame on Jacobs.