Where is the +12 coming from? 17th level PC's with 20 ability scores have +11 and don't have 20 in all stats and proficiency in all checks. It takes expertise or equivalent to get +12; or feat selection or advantage on a passive check.
Seems like we're looking at extremes instead of norms here.
I did have a player who ran a bard that had a ludicrously high perception check. IIRC it was 20 plus between items, feats, expertise and a high wisdom. But he was definitely the exception to the rule.
But even he wouldn't be able to detect a sneak attack if he could not clearly see or hear an enemy before they attacked.