Whatever else one thinks of Barack Obama, I can't imagine anyone -- not even his bitterest detractors -- would call him a political neophyte anymore. Everything else under the sun, FSM knows, but not "political neophyte."
He had to have known what a political hornet's nest he was walking into when he signed off on the Bowe Bergdahl exchange. And I'd bet the ranch that he knew equally well what was going to hit the fan when he got the deal done while leaving out of the loop (possibly more than) a few high-profile congressional intel nabobs -- many of whom could, presumably, have thwarted the deal if they'd been aware of the negotiations.
But Obama went ahead with it anyway because we really don't leave our own behind. Not even if they're suspected of ... whatever. It doesn't matter. We don't leave our own behind. That trumps pretty much everything else in this case.
Whatever does or does not need to happen after that young man comes home is another matter -- and obviously the president knows that, too -- and has seen enough intel to have a pretty good idea where all that's likely to lead.
If there are political points for Obama to score here, I don't see them. And I suspect he also perceived few or none to be had. Only downside.
But he did it anyway -- because some principles we just don't violate. No matter what.