Player agency doesn't extend to the possibility of bad things happening (otherwise characters couldn't get hurt by anything). Depending on the edition, you can search regularly for traps anywhere you expect there might be one. In a skill based edition you don't even necessarily have to describe the action all the time (taking the 10/passive checks take care of that). The problem with this is not traps themselves, but with DMs obsessed with "gotcha." Traps are meant to have a chance of being found and avoided; taking the chance away is the violation of player agency.The argument seems to go like this: traps that are not telegraphed are gotchas, and that's bad because without being able to make an informed decision, my choices as a player are meaningless. The whole point of player agency is to have meaningful choices. Non-telegraphed dangers violate my agency as a player, therefore should not be included in the game.
Traps aren't a waste of time from a worldbuilding perspective, even if they are found and avoided. Not only can the occasional trap trigger, searching for traps takes time for invaders, giving you time to prepare a defense. The pragmatic issue is that traps either need an easy way to be disabled or avoided, otherwise they're more a challenge for the occupants than invaders. Traps in dungeons work pretty well, because there can be multiple paths around them, and PCs should be on the alert for them in such a location anyway.The counter argument seems to go like this: no one would ever build a trap that's obvious or telegraphed, therefore traps that are telegraphed make no sense. This is the immersion and worldbuilding counter. Also, no player is ever going to willingly trigger a telegraphed trap (unless they're a chaos goblin), therefore traps are a waste of time. This is the pragmatic counter.