switch from Prelude.catch (which got removed in ghc-7.6) to Control.Exception.catch