def _getFailure(self, error):
        """
        Convert a C{sys.exc_info()}-style tuple to a L{Failure}, if necessary.
        """
        if isinstance(error, tuple):
            return Failure(error[1], error[0], error[2])
        return error

        Convert a C{sys.exc_info()}-style tuple to a L{Failure}, if necessary.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/trial/reporter.py