The idea behind Erlang’s error handling is that completely avoiding crashes and errors is practically impossible, so the language is designed to gracefully handle crashing "processes" (lightweight threads) and restarting them instantly without the rest of the software being affected. It doesn’t mean the entire program crashes, in fact that’s what this approach prevents.