Skip to content

Commit 778ccb8

Browse files
committed
[DEV-12967] [DEV-12966] Add state_operations back to migration
1 parent b35de3e commit 778ccb8

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

usaspending_api/awards/migrations/0112_move_vw_awards_creation_step.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,13 @@ class Migration(migrations.Migration):
1515
migrations.RunSQL(
1616
sql=vw_awards_sql,
1717
reverse_sql="DROP VIEW IF EXISTS vw_awards",
18-
),
18+
# Without this, Django will try to actually change the old table names in another migration
19+
# This says we've already done it.
20+
state_operations=[
21+
migrations.AlterModelTable(
22+
name="award",
23+
table="vw_awards",
24+
)
25+
],
26+
)
1927
]

0 commit comments

Comments
 (0)