The debate is more pressing than ever.

In overflowing camps in eastern Syria, the wives and children of ISIS fighters who fled the last shreds of ISIS territory are dying of exposure, malnutrition and sickness. Children are too spent to speak. Women who have renounced the group live in dread of attacks from those who have not.

The local militias running the camps say they cannot detain other countries’ citizens forever.

Across the border in Iraq, government authorities are administering hasty justice to people accused of being Islamic State members, sentencing hundreds to death in trials that often last no longer than five minutes.

But most foreign governments are reluctant to take them back, leaving them international pariahs wanted by no one — not their home countries, not their jailers.

“Who wants to be the politician who decides to repatriate Individual A who, two years down the road, blows himself up?” said Lorenzo Vidino, the director of the George Washington University Program on Extremism.

The fact is, Mr. Vidino said, few extremists return to stage attacks in their home countries. But the exceptional cases — including the 2015 Paris attacks that killed 130 people and two of Tunisia’s deadliest terrorist attacks — have made the idea of repatriation politically toxic in many countries. At least one of the bombers who carried out the attack in Sri Lanka on Easter was a Sri Lankan who had trained with the Islamic State in Syria.

Some countries, like Britain and Australia, have revoked the citizenships of their nationals suspected of joining the Islamic State abroad, effectively abandoning them and their children to indefinite detention without charge and potential statelessness. Britain alone has canceled the passports of more than 150 people, the home secretary, Sajid Javid, has said.