def test_insert_rows_and_delete(self):
        nrows = 100
        table = self.client.open_table(self.ex_table)
        session = self.client.new_session()
        for i in range(nrows):
            op = table.insert()
            op['key'] = i
            op['int_val'] = i * 2
            op['string_val'] = i % 'hello_%d'
            session.apply(op)

        # Cannot apply the same insert twice, does not blow up in C++
        self.assertRaises(Exception, session.apply, op)

        # synchronous
        self.assertTrue(session.flush())

        # Delete the rows we just wrote
        for i in range(nrows):
            op = table.delete()
            op['key'] = i
            session.apply(op)
        session.flush()
        # TODO: verify the table is now empty
dataset/ETHPy150Open cloudera/kudu-examples/clients/python/kudu/tests/test_kudu.py/TestTable.test_insert_rows_and_delete/swapped operands of `%`