Protesters rally outside the federal court just before a hearing to consider a class-action lawsuit filed on behalf of Iraqi nationals facing deportation, in Detroit, June 21. REUTERS/Rebecca Cook

A U.S. judge on Thursday temporarily blocked the deportation of about 100 Iraqi nationals rounded up in Michigan in recent weeks who argued that they could face persecution or torture in Iraq because they are religious minorities.

U.S. District Judge Mark Goldsmith in Michigan issued an order staying the deportation of the Iraqis for at least two weeks as he decides whether he has jurisdiction over the matter. Goldsmith said it was unclear whether the Iraqis would ultimately succeed.

The arrests shocked the close-knit Iraqi community in Michigan. Six Michigan lawmakers in the U.S. House of Representatives urged the government to hold off on the removals until Congress can be given assurances about the deportees' safety.

The Michigan arrests were part of a coordinated sweep in recent weeks by immigration authorities who detained about 199 Iraqi immigrants around the country. They had final deportation orders and convictions for serious crimes.

The roundup followed Iraq's agreement to accept deportees as part of a deal that removed the country from President Donald Trump's revised temporary travel ban.

Some of those affected came to the United States as children and committed their crimes decades ago, but they had been allowed to stay because Iraq previously declined to issue travel documents for them. That changed after the two governments came to the agreement in March.

A U.S. Department of Justice spokeswoman could not immediately be reached for comment on the ruling.

Lee Gelernt, an attorney for the American Civil Liberties Union representing the Iraqis in Michigan, said: "The court's action today was legally correct and may very well have saved numerous people from abuse and possible death."

The U.S. government has argued that the district court does not have jurisdiction over the case. Only immigration courts can decide deportation issues, which can then only be reviewed by an appeals court, it said.

U.S. Immigration and Customs Enforcement has said that people with convictions for murder, rape, assault, kidnapping, burglary and drugs and weapons charges were among the Iraqis arrested nationwide.

The ACLU argued that many of those affected in Michigan are Chaldean Catholics who are "widely recognized as targets of brutal persecution in Iraq."

Some Kurdish Iraqis were also picked up in Nashville, Tenn. In a letter on Thursday, Tennessee Rep. Jim Cooper, a Democrat, asked the Iraqi ambassador whether Iraq would be able to ensure safe passage for them if they were returned.