-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
downgrade postgres to 14 cause lack of 15 charm
- Loading branch information
Showing
3 changed files
with
33 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 0 additions & 33 deletions
33
backend/migrations/versions/2023_06_20_1000-b33ee8dd41b1_use_nulls_not_distinct.py
This file was deleted.
Oops, something went wrong.
32 changes: 32 additions & 0 deletions
32
...grations/versions/2023_07_11_1148-158244992900_disallow_multiple_artefact_builds_with_.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
"""disallow multiple artefact builds with null revision | ||
Revision ID: 158244992900 | ||
Revises: b33ee8dd41b1 | ||
Create Date: 2023-07-11 11:48:49.777726+00:00 | ||
""" | ||
from alembic import op | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
revision = "158244992900" | ||
down_revision = "6a80dad01d24" | ||
branch_labels = None | ||
depends_on = None | ||
|
||
|
||
def upgrade() -> None: | ||
op.create_index( | ||
"unique_artefact_build_null_revision", | ||
"artefact_build", | ||
["artefact_id", "architecture"], | ||
unique=True, | ||
postgresql_where=("revision IS NULL"), | ||
) | ||
|
||
|
||
def downgrade() -> None: | ||
op.drop_index( | ||
"unique_artefact_build_null_revision", | ||
"artefact_build", | ||
) |