Nuclear weapons are a special case because they threaten the survival of the human race (you can probably throw certain chemical/biological weapons in here too). Joining NATO--not that the Ukraine was even doing that--does not. There's a material difference here.
Smallish country developing nuclear warhead wont threaten survival of the human race. It wont have neither enough warheads nor sufficient delivery capabilities, yet no country is allowed to enter nuclear club, because existing members sees it as threat and have means to enforce their will. Ukraine joining NATO is same in principle: a threat to someone who is willing to act on it.
> Joining NATO--not that the Ukraine was even doing that