Luke’s Jedi training of Ben Solo (a Skywalker descendant) was clearly such a disaster that it turned him to the dark side
Rey is a Kenobi
Ben Ostrower

It may not have necessarily been the training, as the same thing happened to Anakin Skywalker. Qui-Gon Jinn pestered the Jedi Council to allow him to train Anakin, but Anakin’s fear of losing his mother among other things brought him to the dark side. Ben Solo may be just subconciously following in his grandfather’s footsteps emotionally while he also very consciously follows him in his day-to-day life.

I just wonder if Luke really did “mess up” the training— or if he just made the same mistake of training someone who should not have been trained from the beginning.

But maybe that’s what you mean by “mess up” :)