Python Error Handling
Part I: Famous Software Failures
Therac-25 (1985-1987)
Computer-controlled radiation therapy machine
The Problem:
- Machine could produce:
- Low-energy electron beams
- High-energy X-ray photons
- A turntable must be set up correctly for each mode
- Race condition allowed high-powered beams when turntable was NOT in correct position
- Result: Massively overdosed 6 people; several died
Lesson: Proper error handling and testing of control systems is critical
Ariane 5 Rocket (1996)
The Incident:
- Normal behavior for 36s after lift-off
- Failure of both Inertial Reference Systems simultaneously
- Strong pivoting of nozzles → 90 degree off-course
- Self-destruction at 4000m altitude
- Cost: $7 billion development + $500 million rocket/cargo
What Went Wrong:
- Overflow on one variable representing horizontal velocity