There's also the XY problem problem, where some people expect that every of a complex or unusual question is an instance of the XY problem, even when the requester really does just need a solution to Y.
I’ve also seen a similar phenomenon where I really want to try Y and people just keep telling me a different way to do X that I’ve already tried.
This is something I have known (but not by this name) since the early 90’s. A proposed feature a customer brings to you is almost never what they need. You must iterate with them to discover their real problem and move on from there.
I left a project once because the sponsor wasn’t letting us interact with the real customer to find the real need. That path only leads to doom and despair.
Asking about Y (or Z, or some other problem a few layers down) is common when yak shaving. Aka doing the thing that's needed to do the thing that's needed to do X. Not to be confused with the also-present problem of ADHD sequential distraction by some other unrelated problem (possibly one sighted along the way to eventually get X done).
It's a gross idealization that every problem can be directly solved, or is "shovel ready." In my world there are often oodles of blockers, dependencies, and preparations that have to be put in place to even start to solve X. Asking about Y and Z along the way? Par for the course.
Listen. If someone on stack overflow asks how to do X, do not tell them they don't want to do X unless you explain how they could do X. Maybe that poster would be better off not doing X, but someone else will come along some day who wants X for real.