diff --git a/backend/scripts/soak.py b/backend/scripts/soak.py index 813e2c3..dc1f83d 100644 --- a/backend/scripts/soak.py +++ b/backend/scripts/soak.py @@ -849,13 +849,13 @@ def clear_redis() -> None: def clear_observability() -> None: """The collector wrote rollups, runs and events for the soak flows.""" - names = ", ".join(repr(flow) for flow in FLOWS) + marks = ", ".join("?" for _ in FLOWS) script = "\n".join( [ "import sqlite3", "db = sqlite3.connect('/data/fluksio.db')", *( - f"db.execute('DELETE FROM {table} WHERE flow IN ({names})')" + f"db.execute('DELETE FROM {table} WHERE flow IN ({marks})', {FLOWS!r})" for table in ("metric_minute", "flow_run", "engine_event") ), "db.commit()",