@sessioned
    def find_older_events(self, purge_date, batchsize, session=None):
        # For speed, we do this below the ORM layer. (mdragon)
        conn = session.connection()
        event_table = models.Event.__table__
        q = select([event_table.c.id])
        q = q.where(purge_date < event_table.c.generated)
        q = q.order_by(event_table.c.generated.asc())
        q = q.limit(batchsize)
        return [r[0] for r in conn.execute(q).fetchall()]
dataset/ETHPy150Open openstack/stacktach-winchester/winchester/db/interface.py/DBInterface.find_older_events/swapped operands of `<`