def __enter__(self):
        self._orig = self.db.get_autocommit()
        self.db.set_autocommit(False)
        if self.db.transaction_depth() == 0:
            self._begin()
        self.db.push_transaction(self)
        return self
dataset/ETHPy150Open coleifer/peewee/peewee.py/transaction.__enter__/original