Metagame knowledge of traps can make the game awkward. I’ve maintained in the past that the best traps are blatantly obvious and the trick is not detecting them but figuring out a way past them. (Ironically, my book of Traps of the DMsGuild contains few of these.) But that knowledge of the trap works best if both characters and players recognise the likely presence of a trap. Things get trickier when the players get a sense things are going too well or recognize an obvious trap pulled from film: adventurers are unlikely to have seen Raiders of the Lost Ark and know what will happen when step into the beam of light or pick-up a golden idol.

This goes double if they just botched a Perception check, which their characters would not know. The character should believe things are fine because they checked and has no reason for caution, but the player knows better.