As a federal judge heard arguments on Thursday seeking to halt the deportations of several Central American women requesting asylum, he learned that a woman and her daughter at the center of the case had been ushered from a Texas shelter, driven to an airport and put on a plane to El Salvador. The judge ordered the government to bring the two back immediately.

The judge, Emmet G. Sullivan of the District of Columbia, criticized the government for deporting the pair just as they were seeking justice in court. In ordering the government to undo the deportation, he threatened to hold government officials, from Attorney General Jeff Sessions on down, in contempt, said a lawyer for the plaintiffs.

Twelve women and children who are plaintiffs in the case, filed by the American Civil Liberties Union against Mr. Sessions and several other administration officials, had been put on the fast track to deportation in the face of a directive from Mr. Sessions that fear of gangs and domestic violence would no longer be an acceptable basis for people to seek asylum in the United States.

Mr. Sessions’s decision in June blocked a major route for people seeking asylum and was poised to have an especially strong impact on Central American women, tens of thousands of whom have arrived at the border citing those fears in the past several years.