Protecting an IO pin from a spike
I was switching some electro valves, and it turns out that I (somehow) forgot the flyback diodes on their coils. The massive spike came from a separate circuit, but it was enough to mess with my circuitry.