From 2eab5fd2b7f980d355caa53be582aa07dc65a8e2 Mon Sep 17 00:00:00 2001 From: Jamie Lennox Date: Tue, 16 Apr 2013 13:14:21 +1000 Subject: [PATCH] Remove new constraint from migration downgrade. Remove the foreign key constraint for user_id. Whilst it is a foreign key the constraint was not set in the previous schema. Also sets the columns names to unicode as they were in previous schema. Fixes: bug 1169381 Change-Id: I9b1ac5305622d68a7e124ba8100a4b8166b43af0 --- .../versions/020_migrate_metadata_table_roles.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/keystone/common/sql/migrate_repo/versions/020_migrate_metadata_table_roles.py b/keystone/common/sql/migrate_repo/versions/020_migrate_metadata_table_roles.py index 4d0f9dfcf2..b60dacb113 100644 --- a/keystone/common/sql/migrate_repo/versions/020_migrate_metadata_table_roles.py +++ b/keystone/common/sql/migrate_repo/versions/020_migrate_metadata_table_roles.py @@ -70,12 +70,11 @@ def downgrade(migrate_engine): 'metadata', meta, sql.Column( - 'user_id', + u'user_id', sql.String(64), - sql.ForeignKey('user.id'), primary_key=True), sql.Column( - 'tenant_id', + u'tenant_id', sql.String(64), primary_key=True), sql.Column('data',