North Korea wouldn't be one of the most sanctioned countries on Earth if its leaders simply stopped dealing in illegal weapons trades. As Kim Jong Un's regime continues to illegally provoke the world through its obsession with launching nukes, its government officials, in turn, have resorted to other illegal means to gain the resources necessary for such missiles. Sanctions would be lifted and the world would be safer if the North abided by international law.
The West doesn't sanction North Korea because it violates international rules but because the North, in its pursuit of military prowess, won't bend to the demands of America's rules. If Pyongyang gets scolded for launching spy satellites and missiles, why don't South Korea or the US face retribution for developing the same technologies and aiming them at the North? This is about who gets to be in charge, not who has weapons.