antithesis-tests: Don't fail tests on ProgrammingError

The ProgrammingError exception is thrown when tables, indexes, or
columns are dropped in parallel. Let's not fail the Antithesis test
drivers when that happens.
This commit is contained in:
Pekka Enberg
2025-10-21 19:18:43 +03:00
parent d2d995a9c0
commit 4805c6b06b
9 changed files with 67 additions and 23 deletions

View File

@@ -46,6 +46,10 @@ for i in range(insertions):
INSERT INTO tbl_{selected_tbl} ({cols})
VALUES ({", ".join(values)})
""")
except turso.ProgrammingError:
# Table/column might have been dropped in parallel - this is expected
con.rollback()
break
except turso.OperationalError as e:
if "UNIQUE constraint failed" in str(e):
# Ignore UNIQUE constraint violations