def create_revision(self, **kwargs):
        kwargs.setdefault('sha', uuid4().hex)
        if not kwargs.get('repository_id'):
            if not kwargs.get('repository'):
                kwargs['repository'] = self.create_repo()
            kwargs['repository_id'] = kwargs['repository'].id

        if kwargs not in 'author':
            kwargs['author'] = self.create_author()

        if kwargs.get('author'):
            kwargs['author_id'] = kwargs['author'].id

        if not kwargs.get('message'):
            message = get_sentences(1)[0][:128] + '\n'
            message += '\n\n'.join(get_paragraphs(2))
            kwargs['message'] = message

        revision = Revision(**kwargs)
        db.session.add(revision)
        db.session.commit()

        return revision
dataset/ETHPy150Open dropbox/changes/changes/testutils/fixtures.py/Fixtures.create_revision/swapped operands of `not in`