Principle: Sometimes a player's mistakes aren't really mistakes. If a player has no good reason to believe a particular action might lead to failure, then failure should not be blamed on the player.
Failure by surprise occurs when the player's actions do not appear as if they should lead to failure, because the relationship between action and outcome is either obscure or counterintuitive, or because the element that makes a particular action lead to failure is presented too late for the player to react to it. King's Quest and Dragon's Lair are known for this kind of failure mechanism, where the wrong move can easily result in unexpected death or failure1.
A game should generally provide enough clues for players to anticipate danger, and should otherwise give players a fair chance to react to any surprises.
1. See Ways to Die/Lose in King's Quest and Let's Fail Dragon's Lair v2.0 (not safe for work).