Add error handling for largely unrecoverable errors