As set_object, but restricts the type of object to be a Commit

        :raise ValueError: If commit is not a Commit object or doesn't point to
            a commit
        :return: self
507680
def set_commit(self, commit, logmsg=None):
        """"""
        # check the type - assume the best if it is a base-string
        invalid_type = False
        if isinstance(commit, Object):
            invalid_type = commit.type != Commit.type
        elif isinstance(commit, SymbolicReference):
            invalid_type = commit.object.type != Commit.type
        else:
            try:
                invalid_type = self.repo.rev_parse(commit).type != Commit.type
            except (BadObject, BadName):
                raise ValueError("Invalid object: %s" % commit)
            # END handle exception
        # END verify type

        if invalid_type:
            raise ValueError("Need commit, got %r" % commit)
        # END handle raise

        # we leave strings to the rev-parse method below
        self.set_object(commit, logmsg)

        return self
968077
def account_id(self, value):
    
    if type(value) is not str:
      raise TypeError("commit value must be string")
    self._account_id = value
748925
def commit(self, callback=None):
        ''''''
        if self.executed:
            raise InvalidTransaction('Invalid operation. '
                                     'Transaction already executed.')
        session = self.session
        self.session = None
        self.on_result = self._commit(session, callback)
        return self.on_result
1339024
def commit(cls, client=None):
        
        if not client:
            client = cls._client
        rtn = client.write_points(cls._json_body_())
        cls._reset_()
        return rtn
694927
def set(self, instance, value, **kw):
        
        return self._set(instance, value, **kw)
875490
def commit(self, transaction=None, headers=None, **keyword_headers):
        
        assert transaction is not None, "'transaction' is required"
        headers = utils.merge_headers([headers, keyword_headers])
        headers[HDR_TRANSACTION] = transaction
        self.send_frame(CMD_COMMIT, headers)
796838
def commit(self):
        
        self._check_thread()
        if self.state != _STATE_ACTIVE:
            raise TransactionError("Transaction is not active.")
        try:
            self._check_timeout()
            request = transaction_commit_codec.encode_request(self.id, self.thread_id)
            self.client.invoker.invoke_on_connection(request, self.connection).result()
            self.state = _STATE_COMMITTED
        except:
            self.state = _STATE_PARTIAL_COMMIT
            raise
        finally:
            self._locals.transaction_exists = False
1111754
def set(self, obj, value):
        
        assert self.setter is not None, "Setter accessor is not specified."
        if callable(self.setter):
            return self.setter(obj, value)

        assert isinstance(self.setter, string_types), "Accessor must be a function or a dot-separated string."

        def _set(obj, attr, value):
            if isinstance(obj, dict):
                obj[attr] = value
            else:
                setattr(obj, attr, value)
            return value

        path = self.setter.split(".")
        for attr in path[:-1]:
            obj = _set(obj, attr, {})

        _set(obj, path[-1], value)
27061
def commit(self, commit):
		
		try:
			changesets = self.repo.log(revrange=commit)
		except error.CommandError:
			raise KeyError("Commit %s not found" % commit)

		return self._commitData(changesets[0])
557746
def commit(self, revision, is_amend=False):
        
        if not isinstance(revision, Revision):
            raise InvalidArgType()

        if not self.current_client:
            raise ClientNotSpecified()

        if is_amend:
            self.current_client.save(revision)
        else:
            self.current_client.write()
            self.current_client.save(revision)

        return self
288814
def set_object(self, start, obj, object_size):
        

        self._store(start, obj, object_size, overwrite=True)
1207949
def commit(self):
        

        try:
            self.check_connection()
        except NullDatabaseConnectionError:
            return

        logger.debug("commit: path='{}'".format(self.database_path))

        try:
            self.connection.commit()
        except sqlite3.ProgrammingError:
            pass
182285
def transaction_type(self, value):
        """"""
        if value is not None:
            if value not in self.ALLOWED_TRANSACTION_TYPES:
                raise AttributeError('%s transaction_type element must be one of %s not %s' % (
                    self.__class__.__name__, ','.join(self.ALLOWED_TRANSACTION_TYPES), value,))
        self._transaction_type = value
527579
def save(self, commit=False):
        
        if not has_identity(self):
            # Object has not been persisted to the database.
            session.add(self)

        if commit:
            # Commit the session as requested.
            session.commit()

        else:
            # Just flush the session; do not commit.
            session.flush()
598270
def commit(using=None):
    
    if using is None:
        for using in tldap.backend.connections:
            connection = tldap.backend.connections[using]
            connection.commit()
        return
    connection = tldap.backend.connections[using]
    connection.commit()
40039
def commit(self, commit):
		
		try:
			return self._commitData(self.repo.get_commit(commit))
		except (ValueError, KeyError, GithubException):
			raise KeyError("Commit %s not found" % commit)
284961
def commit(self) -> None:
        
        if len(self._transactions) == 0:
            raise RuntimeError("commit called outside transaction")

        # If we have nested transactions, we don't actually commit, but push
        # rollbacks up to previous transaction.
        if len(self._transactions) > 1:
            for on_rollback in reversed(self._transactions[-1]):
                self._transactions[-2].insert(0, on_rollback)

        _debug("commit")
        self.reset()