You could also place cats around your town, since phantoms are scared of them.
It will also protect it from creepers, which will run away too.
Might get pretty annoying placing them everywhere but it's a quiet cute solution for the problem ^-^)=
I've tried many TNT duper, the same as a tripwire hook and rail duper which all aren't funktioning properly.
They are all designed to function in 1.16.4...
even the TNT duper I use in my singleplayer world, is just not working.
Seems like the server fixed them eventhough the name of the gamemode is vanilla.
Are TNT duper allowed to use in the vanilla Gamemode?
For example in a tree farm or to excavate a big hole.
They haven't been fixed by Mojang, so I see them as a feature.
Still I hope it's not bannable on GhibliCraft :3