def callWrapper(self, protocol, port, methodname, authToken,
                    orderedArgs, kwArgs,
                    remoteIp = None, rawUrl = None, isSecure = False,
                    systemId = None):
        self._port = port
        self._protocol = protocol
        self._baseUrlOverride = rawUrl

        if methodname not in self.publicCalls:
            raise errors.MethodNotSupported(methodname)

        method = self.__getattribute__(methodname)

        # Repository in read-only mode?
        if method._accessType == 'readWrite' and self.readOnlyRepository:
            raise errors.ReadOnlyRepositoryError("Repository is read only")

        if (hasattr(method, '_minimumClientProtocol') and
                        method._minimumClientProtocol > orderedArgs[0]):
            raise errors.InvalidClientVersion(
                    '%s call only supports protocol versions %s '
                    'and later' % (methodname, method._minimumClientProtocol))

        # reopens the database as needed (if changed on disk or lost connection)
        self.reopen()

        exceptionOverride = None
        start = time.time()
        try:
            r = self._callWrapper(method, authToken, orderedArgs, kwArgs)
            if self.db.inTransaction(default=True):
                # Commit if someone left a transaction open (or the
                # DB doesn't have a way to tell)
                self.db.commit()
        except Exception, e:
            # on exceptions we rollback the database
            if self.db.inTransaction(default=True):
                self.db.rollback()
        else:
            if self.callLog:
                self.callLog.log(remoteIp, authToken, methodname,
                                 orderedArgs, kwArgs,
                                 latency = time.time() - start,
                                 systemId = systemId)
            return r

        if self.callLog:
            if isinstance(e, HiddenException):
                self.callLog.log(remoteIp, authToken, methodname, orderedArgs,
                                 kwArgs, exception = e.forLog,
                                 latency = time.time() - start,
                                 systemId = systemId)
                exceptionOverride = e.forReturn
            else:
                self.callLog.log(remoteIp, authToken, methodname, orderedArgs,
                                 kwArgs, exception = e,
                                 latency = time.time() - start,
                                 systemId = systemId)
        elif isinstance(e, HiddenException):
            exceptionOverride = e.forReturn

        if isinstance(e, sqlerrors.DatabaseLocked):
            exceptionOverride = errors.RepositoryLocked()

        if exceptionOverride:
            raise exceptionOverride

        raise
Returns a tuple of (Exception, result).  Exception is a Boolean
dataset/ETHPy150Open sassoftware/conary/conary/repository/netrepos/netserver.py/NetworkRepositoryServer.callWrapper