

def execute(self):
    if (self._dirty or (self._qr is None)):
        model_class = self.model_class
        query_meta = self.get_query_meta()
        ResultWrapper = self._get_result_wrapper()
        self._qr = ResultWrapper(model_class, self._execute(), query_meta)
        self._dirty = False
        return self._qr
    else:
        return self._qr

dataset/ETHPy150Open coleifer/peewee/peewee.py SelectQuery.execute/original