I call this Phantom Failure. I think in baseball it's called the yips.....
Just some insight by way of my own experience with one of my gymnasts. I had this kid that moved like silk...power combined with grace, joined by an acute awareness for time/space/and position. Normally this would lead to great things, and it did until she started doing more complex skills and would stop in the middle of an attempt and claim she just couldn't finish it.
One day I realized that she was the "best dresser" in the gym and was always color co-ordinated in every way possible. So I asked her how long it took to choose which clothes to wear for school and she replied "about 30 to 40 minutes". Wow!, this girl couldn't make up her mind about something as simple as which clothes to wear. This led me to suspect that her inability to decide, combined with a body awareness that allowed her to feel even the slightest deviation from what she had defined as perfection was causing these aborted attempts.
To overcome this I had to totally convince her that even her worst efforts would be safe 99.999% of the time, and if she would just complete the attempt she could learn how easily the skill could be performed. It didn't have to come close to perfection and that our "new perfection" would be to complete every skill no matter how "off" it felt. We started out small with some spotting and worked our way up to the most difficult skills and over time, with a ton of positive reinforcement, she was able to perform comfortably.
I'm not saying this is the case with every Phantom Failure but it is an illustration of how complex this issue can be. And I'm sorry if the word failure isn't pc but I started calling it that so long ago that I can't stop and in that way I'm a failure too.