Update error re-raising to use a more Python 2/3 compatible version.