That's one damn good assumption, but I don't see that many episodes suggesting that Terrans are so militaristic and violent in FS. It may be true, I'm not excluding it, but we lack a decisive proof.
The Neo-Terran Front rebellion wouldn't have started if the Terran race wasn't militaristic and violent. If the Terrans were benevolent that rebellion wouldn't have started.
Perhaps it's only a small portion of the Terran race that is like that, but as long as there are a few disillusioned Terrans out there they will continue to influence the political situation, making capital punishment necessary.
Things are changing. We're far from perfect, but things are finally changing.
As I said elsewhere, only countries with a certain reputation keep relying on death penalties. Namely: China, Iran, and many others. In other words, it's not a good thing.
As I said, there is a lot of different levels in Terran society - Some civilizations are more advanced than others. If we're taking a (
very dangerous) assumption that the USA are the most advanced civilization, with their fair trials and all, there are still a lot of civilizations that are less advanced, such as the PRC which still advocates some heavy-handed government stuff. In 300 years, maybe the most advanced civilization would have done away with the death penalty, but some voices will still call for it. Especially in a time of war.