You kidnap a civilian at gunpoint and force them to trigger the trap. It's called the "Mosquito Protocol", an IDF classic: https://www.haaretz.com/opinion/2025-03-30/ty-article-opinio...
Or, if you are not a genocidal terror group, you actually go house-to-house and check. Difficult, dangerous, but not a war crime. That's why Mosul isn't a pile of rubble, even though ISIS was more than willing to use booby traps!
---
"We are demolishing more and more homes, they have nowhere to return. The only obvious result will be the desire of the Gazans to emigrate outside the Strip. Our main problem is in the receiving countries."
—Benjamin Netanyahu, 2025