It's not that rare, and there are institutional factors (such as seeking treatment for psychosis being career-ending for a pilot) that incentivize serious pilot mental health crises being untreated.
All commercial plane crashes are very rare occurrences.