PHILADELPHIA — A lawyer arguing a lawsuit aimed at forcing a do-over of Pennsylvania’s congressional map says a powerful politician on other side was only trying to delay the case by calling for it to be moved from state to federal court, then withdrawing that request at the last minute.

The matter came to a head Thursday in a federal courthouse in Philadelphia, where a judge decided it would remain in a state court.

Republican state Senate President Pro Tempore Joseph Scarnati III had requested that the case be moved from the state Supreme Court to federal courts, which are considering two other claims of improper gerrymandering in Pennsylvania. Scarnati is one of the defendants in the case, which was filed by 18 Democratic voters who claim the map was made unfairly to benefit Republicans.

Lawyers for the plaintiffs contend the case belongs in state court because its claims are based on the state constitution, unlike the other two cases that rely on the U.S. Constitution.

Time was of the essence. The matter is scheduled for a Dec. 11 trial before the Pennsylvania Supreme Court. A pre-trial hearing was scheduled for Thursday but scrapped because of the request to switch courts.

But by Thursday afternoon, at least two other defendants, including Republican House Speaker Mike Terzai, said they wanted the case to stay where it was.

U.S. District Court Judge Michael Baylson said the case would stay in state court.

He gave Stanton Jones, a lawyer for the 18 voters, a chance to vent. Jones said the legal maneuvers served “no purpose other than delaying” the case and asked for the other side to reimburse his fees and expenses.

Scarnati’s lawyer, Matthew Haverstack, apologized to the other lawyers and insisted the request was filed in good faith. “Nobody likes to conduct business in this way,” he said.

A trial in one of the federal cases over Pennsylvania’s district lines is scheduled to start Dec. 4, a week before the state case.

The cases have different legal theories, but both say it’s a problem that a state where Republican and Democratic candidates for the U.S. House of Representatives get about equal numbers of votes is represented by 13 Republicans and five Democrats.

Meanwhile, the parties are waiting to see how the U.S. Supreme Court rules on a gerrymandering case out of Wisconsin.