It is a fantasy, but it's distinct in that it's a rare projection of the human future that isn't Blade Runner, Max Max, Terminator, anything from Black Mirror. That's what makes it interesting. Bleak futures are a dime a dozen; nothing wrong with a bit of positivity.
To address the OP though, Star Fleet was always a ridiculous construct. From the Wesley episodes I'm given the impression that even to get in you have to be some kind of super-genius (and then they deny the other 3 super-geniuses entry, cos hey, I guess we got too many in the future) and yet we can waste these guys redshirting them. And that doesn't explain how there seems to be so many dumb people in Starfleet.