I think if it's wrong we shouldn't do it (because we shouldn't do things that are wrong), and if it's not wrong we shouldn't punish other people for doing it (because we shouldn't punish people for doing things that are not wrong). Yes, this is exactly attempting to apply personal morality to the "international system". Which is made up of people who make conscious decisions about how to behave toward other people.
I can do that. Nobody should lie, it's wrong. So, as long as every nation stops lying, they can stop spying too. Easy Peasy.
> Shouldn't we care whether the things that the justice system is punishing people for are things that are actually good or bad?
Absolutely. Which is why usually friendly-nation spies don't seem to get in trouble. Take a look at this list, https://en.wikipedia.org/wiki/List_of_imprisoned_spies
I think lying/misrepresenting is bad and very harmful, however I also think it is human nature, and spying helps to alleviate that information asymmetry.