Skip to content

Commit 81143e2

Browse files
committed
add missing primary key constraints
addresses #7128
1 parent 84c36a8 commit 81143e2

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# Licensed under the Apache License, Version 2.0 (the "License");
2+
# you may not use this file except in compliance with the License.
3+
# You may obtain a copy of the License at
4+
#
5+
# http://www.apache.org/licenses/LICENSE-2.0
6+
#
7+
# Unless required by applicable law or agreed to in writing, software
8+
# distributed under the License is distributed on an "AS IS" BASIS,
9+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10+
# See the License for the specific language governing permissions and
11+
# limitations under the License.
12+
"""
13+
create missing primary key constraints
14+
15+
Revision ID: b5bb5d08543d
16+
Revises: 08aedc089eaf
17+
Create Date: 2019-12-19 14:27:47.230249
18+
"""
19+
20+
from alembic import op
21+
import sqlalchemy as sa
22+
23+
24+
revision = 'b5bb5d08543d'
25+
down_revision = '08aedc089eaf'
26+
27+
def upgrade():
28+
op.create_primary_key(None, "release_files", ["id"])
29+
op.create_primary_key(None, "release_dependencies", ["id"])
30+
op.create_primary_key(None, "roles", ["id"])
31+
32+
33+
def downgrade():
34+
raise RuntimeError("Order No. 227 - Ни шагу назад!")

0 commit comments

Comments
 (0)