That's not a safe assumption. A nuclear war is far more likely to be a limited local exchange than the all-out-war imagined during the cold war. So you're unlikely to be killed outright by the exchange. Instead you're likely to to have to deal with the nuclear radiation fallout, severe food insecurity and increased global tension.
Perhaps it's unlikely to be "all out" nuclear warfare. Climate change is projected to kill a small number of millions of people. It wouldn't take much for a limited nuclear war to kill more than that.
Wait until bioweapons are made and inevitably leak from a BSL-max lab. That's like if the nukes were invisible, without number, and diligently tracked every individual down.
Unlike nukes, that's extinction time.
Not if we become multiplanetary by then though.
Plus, as we now know, the attacker might be able to rely on a sizable portion of the target population downplaying, denying, and deliberately spreading, and otherwise politicizing the bio agent. You don't get that with nukes. Once the bombs start dropping, nobody's going to have the time to spread conspiracy theories.
Our current situation is very close to how WWI expanded from a regional squabble. Look to that one and ignore WWII to see how it might occur.