I used to do reliability analyses for a large aerospace contractor, I may have some insights. The stuff I worked on was not HSF (Human Space Flight) just automated sats and the like. Each and every single part is spoken for and tallied. Each resistor on a PCB, each explosive bolt, each screw and panel. All of it has a lifetime curve, typically a Bathtub plot, to an extreme degree. Resistors were tested in vast batches, over vast I-V ranges, in hard radiation and vacuum, in vibe, for long periods. You calculate it all out. Something approaching the far upper reaches of the expected 'black swans' is tested and the part is proofed against it. Our stuff was just comms and the like, granted, but even then, the expected lifetime of each satellite was fairly well known out to about 20 years in orbit. A typical figure for a 15 year mission was a 75% chance of it making it the whole way, including launch. It's checked to an extreme degree. I've had people come back and correct an un-dotted 'i' symbol in a handwritten notebook. Really.
HSF is easily 100x higher tolerances.
Some stuff, you have to live with, some stuff (like the panels and the o-rings) is too far fetched for even NASA to think up beforehand. And if you've ever been to The Cape, you know they will never forgive themselves. They try their very best to think it all up. They really really do. NASA may be full of brains, but damned if they aren't all real heroes there on the ground. Those folk have heart more than anything else.
Per Aspera Ad Astra does not fucking cut it.