The Fort Worth district was the only one the Supreme Court agreed had to change, upholding the San Antonio court's ruling that state lawmakers in 2013 moved voters in and out of the district based on their race to keep the white incumbent, Lon Burnam, in office.

Ramon Romero, a Latino, defeated Burnam in 2014's Democratic primary for Texas House District 90.

The Texas Latino Redistricting Task Force, a group of Latino voters and advocacy groups in the state, had asked the court to revert the district back to the shape it was in 2011. The state, which has defended its electoral maps in court since then, said no changes were necessary. But if changes are made, the state's lawyers argued, they should affect only the boundaries drawn in 2013 that the court found discriminatory.

The court ruled that the district needs to change before the 2020 elections. It could have redrawn the district's boundaries, but courts generally let state legislatures act first.

"Before this Court undertakes the 'unwelcome obligation' of fashioning a remedial plan, the Court must afford the Legislature an opportunity to reapportion during either a 2018 special session or the 2019 regular legislative session," Judge Xavier Rodriguez wrote in the order.

It would be up to Gov. Greg Abbott to call a special session in 2018. His office did not immediately respond to a request for comment.

In the order, Rodriguez warned the state against inaction.

"If no action is taken to introduce a redistricting bill within the first 45 days of the 2019 regular session, or if it otherwise is made apparent that no redistricting legislation will be considered during the session, the Court will proceed with a remedial phase," he wrote.

The court didn't rule on whether the state will be brought back under federal supervision for future changes to its voting laws. Several plaintiffs had asked for the federal protection, known as "pre-clearance," under the Voting Rights Act.

The court gave plaintiffs until Nov. 30 to present their briefs arguing for federal supervision. The defendants would have until January 15 to respond.

Rep. Rafael Anchia, a Dallas Democrat who leads the Mexican American Legislative Caucus, one of the plaintiffs, saw positive signs in the order.

"Our goal is to ensure that the people of Texas have the opportunity to elect their candidate of choice. The voters of HD 90 deserve a swift remedy," he said in a prepared statement. "We thank the court for moving quickly to address the possibility of pre-clearance and encourage the state to do the same for the voters of Tarrant County."

CORRECTION, 2:26 p.m., Aug. 31, 2018: An earlier version of this story incorrectly identified the plaintiffs in the Texas redistricting case who have asked to return a Fort Worth district to its 2011 boundaries. That request was made by the Texas Latino Redistricting Task Force, a group of Texas voters and advocacy groups.