refactor(db)!: finalize pooled WNDB v2 migration

This commit is contained in:
2026-08-27 17:26:22 +08:00
parent fa188af0b1
commit b74799a39d
105 changed files with 4988 additions and 5565 deletions
+4 -1
View File
@@ -93,7 +93,10 @@ def _delete_pattern(name: str, cs: ChangeSet) -> DatabaseCommand:
id = cs.operations[0]['id']
f_id = sql_literal(id)
statement = f"delete from network.patterns where id = {f_id};"
statement = (
f"update network.demands set pattern_id = null where pattern_id = {f_id};"
f"\ndelete from network.patterns where id = {f_id};"
)
change = g_delete_prefix | { 'type': 'pattern' } | { 'id': id }