I would love to be a fly on the wall when someone tries using that excuse in a war zone xD In a way I'm thankful for it. It means that most people never even came close to real consequences of their actions...
I'm not sure how the legal system in Ukraine works but for criminal charges you typically you need to prove intent. "Stupidity" would probably be a valid excuse in that case because it implies lack of intent, at least pertaining to the charge of betraying the country.