The state of Texas is in the midst of an extraordinary losing streak in federal courts over the way it conducts elections. It is hoping the Supreme Court will come to the rescue.

In the past couple of weeks, federal judges in four separate cases ruled that the Texas Legislature discriminated against minorities in drawing congressional and legislative districts, setting ID requirements for voters and even regulating who can assist voters for whom English is not their first language.

Two courts are considering whether the actions intended to discourage African American and Hispanic voters. If the courts find that the efforts were intentional, it could return Texas to the kind of federal oversight from which the Supreme Court freed it and other mostly Southern states in the landmark 2013 decision in Shelby County v. Holder.

As the decisions piled up, Texas Attorney General Ken Paxton (R) issued a string of statements denouncing the rulings, calling them “outrageous” and “astonishing.”

On Friday afternoon, he went to the Supreme Court for emergency relief rather than comply with a ruling that the state should call a special legislative session to draw new electoral districts in time for the 2018 elections.

The decision by a three-judge panel ordering new districts “is not just wrong, but egregiously so,” Texas told the Supreme Court.

But Democrats and civil rights activists in the state say the seemingly endless litigation over voting laws and redistricting decisions — and the comeuppance from federal courts — are the inevitable result of the Republican-led state’s aggression.

“It’s been a bad month for Governor Abbott and Attorney General Paxton,” said state Rep. Eddie Rodriguez, policy chair of the Mexican American Legislative Caucus, a plaintiff in the lawsuits. “Federal courts have issued three findings of intentional discrimination by the Texas Legislature in the past two weeks alone, evidence of its total disregard for the federal Voting Rights Act following the 2010 tea party surge.”

A finding of intentional discrimination is especially important.

In the Shelby County decision written by Chief Justice John G. Roberts Jr., the court made unenforceable the part of the Voting Rights Act that required Texas and other states with a history of discrimination to get federal approval before making any changes to election laws.

But the decision retained a portion of the law that could put states back under the pre-clearance requirements — for up to 10 years — if courts find the states had engaged in intentional discrimination.

“It’s no surprise the issue of ‘bail-in’ is coming up in Texas,” said Richard Hasen, a voting law expert at the University of California in Irvine. “It and North Carolina are the places most aggressive” in passing and enforcing new laws after the Shelby County decision was handed down, he said.

A panel of the U.S. Court of Appeals for the 4th Circuit struck down in 2016 a comprehensive voting law passed by the North Carolina legislature, saying Republican lawmakers had targeted African American voters “with almost surgical precision.”

But the panel did not seek to put the state back under federal oversight. The Supreme Court turned down North Carolina’s request to review the 4th Circuit ruling.

Texas has had an even more extended losing streak in the federal courts. Every court that has reviewed its comprehensive voter-ID law passed in 2011 — including the U.S. Court of Appeals for the 5th Circuit, considered one of the most conservative in the country — has concluded that the law has a discriminatory effect on minorities.

Last week, U.S. District Judge Nelva Gonzalez Ramos, who was the first to find the Texas law discriminatory, ruled that changes enacted by the Texas Legislature this year to try to remedy its flaws were no better.

Ramos said the legislature didn’t make a sincere effort to correct problems and “trades one obstacle to voting with another.”

She said she will hold a hearing next month to consider returning Texas to federal oversight. A decision in the affirmative would surely be appealed to the Court of Appeals for the 5th Circuit and, depending on the outcome, to the Supreme Court.

The three-judge panel that found some congressional and some legislative districts must be redrawn also found the legislature intended to discriminate against minorities.

The panel has not ruled on whether that should subject the state to the old pre-clearance requirements, which demanded the approval of the Justice Department or a panel of federal judges in Washington.

Texas has called the recent rulings unreasonable, saying that both in adopting the electoral maps and in changing the voting law the legislature was trying to satisfy judicial demands.

“Simply put, the same map cannot be perfectly permissible when imposed by a court, but become intentionally discriminatory when adopted by the branch of government actually tasked with drawing maps,” the state says in its petition to the Supreme Court.

In the initial challenges to the law in North Carolina and Texas, civil rights activists had an active partner in the Obama administration’s Justice Department. But the department switched sides in the Texas voter-ID law when President Trump took office, saying Texas’s changes were satisfactory.

And, of course, the Supreme Court has changed, too. It declined to get involved in the Texas voting case when the court had only eight justices, before the recent appointment of Justice Neil M. Gorsuch; Roberts said earlier this year there was still work for the lower courts to do.

Texas’s emergency request in the redistricting case will force the court’s hand.