It was never ‘good’. It was regarded as necessary to the times and could be justified on that basis. Today as the Catechism states.
CCC2267 …Today, however, there is an increasing awareness that the dignity of the person is not lost even after the commission of very serious crimes. In addition, a new understanding has emerged of the significance of penal sanctions imposed by the state. Lastly, more effective systems of detention have been developed, which ensure the due protection of citizens but, at the same time, do not definitively deprive the guilty of the possibility of redemption.
Consequently, the Church teaches, in the light of the Gospel, that “the death penalty is inadmissible because it is an attack on the inviolability and dignity of the person”,i and she works with determination for its abolition worldwide.
If you mistakenly thought that the early Fathers taught that the death penalty was always ‘good’ no matter what, the Church has corrected that mistake now. It is only justified if it serves the common good.