North Korea does nuclear tests all the time. If they did it in the middle of international waters, do you think that would result in military action against them? I highly doubt it
I think there would be military action, at least if it was clear they'd done it and there wasn't plausible deniability that it was one of the ones that went missing during the Cold War.
There is nothing above the sovereign nations and they are only bound by their treaties, bilateral and multilateral - despite having a name like "United Nations Convention on the Law of the Sea", this is not some law which UN could pass or modify, it's a treaty which is binding only on those who sign it, and any modifications to add extra restrictions it will be binding only to those ships whose countries agree to these restrictions. UN (and any other international organization) is subservient to the sovereign countries or a place of discussion, not some "world government" above them.
One country using the threat of violence to stop non-violent (but still bad) acts by citizens of another country in neutral territory seems like a bad idea.
This is basically all of human history, laws and being imprisoned - holding someone against their will counting as a more modern, refined form of violence, though necessary.
But for that specific scenario, yes it is a bad idea for all sorts of reasons. But only because we're just a bunch of animals on a rock and we just can't seem to agree to play nice with each other.
The catastrophe of tossing plastics into the ocean is arguably worse than the combined sinking of ships with cannons. But to call it violent because of the cumulative pain it indirectly causes is still a different, more abstract concept of pain than direct infliction. I’m not opposed to acknowledging either as pain, or to say that either is the worst, but they’re different.
Do you want China to start cruising around the world and arbitrarily enforcing their laws on other citizens?