'Patches the error to show the stage that it arose in.'

def _patch_error(self, desc, exc):

    newmsg = '{desc}\n{exc}'.format(desc=desc, exc=exc)
    if (not utils.IS_PY3):
        fmt = 'Caused    By:\n{tb}\n{newmsg}'
        newmsg = fmt.format(tb=traceback.format_exc(), newmsg=newmsg)
    exc.args = (newmsg,)
    return exc
