It depends, I don’t know the exact circumstances, if it was some sort of internal thing where something might have gone wrong, then this is wrong, especially if their own scholars said so, this sort of crime should be hidden from the court itself imho, or atleast not a straight up death penalty, if they were a public school shooter who had killed kids, the issue becomes different
The problem being that it may give them more a tamgible sense of death rather than of consequences.
It seems that murders are committed in scenarios where consideration of the consequences is not even on the radar, instead it's some sudden rage or psychopathy, and I could believe either to be stoked by witnessing execution desensitizing then to violent death.